Building a Simple Blog Engine with ASP.NET MVC and LINQ - Part 4
page 2 of 8
by Keyvan Nayyeri
Feedback
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 461480/ 1998

A Short Overview of Unit Testing

Test-Driven Development (aka TDD) is nowadays the most common way to develop software among architects and developers. Raise of Agile development methodologies and the growing number of small software teams is the main reason to choose TDD as the main option for developing software (of course there are some other reasons as well).

I suppose that you (as readers of this article) have a background in TDD and unit testing from the past because there is no doubt that I cannot teach you such stuff here, but a short related introduction to the topic of this article is mandatory.

The main and most common part of TDD is unit testing. Unit testing is a process and a set of techniques to divide an application into smaller (small) units that are independent from each other and can work isolated then test each unit to make sure it works as expected.

Unit testing works based on some principles. The first one is breaking the application into small pieces which lets you examine their working easily. The second principle is the fact that these units are isolated and work independently from others. This isolation lets you change a unit without having any effect on another unit.

Unit testing techniques test these pieces to see if each piece works as expected for different situations and input data. In this case, once you pass all tests, you can move on to the next stage in your development. But the good point is the fact that if you change other elements and units of the code then they would not break your existing code and if they do (which is not surprisingly unexpected) then your existing tests will fail and alert you about a problem.

So you can go back and forth and refractor your code without breaking existing code and consistency of your code and this is the main reason that many developers have chosen this as their primary process for development.

However, I cannot talk much about Test-Driven Development and unit testing here and I should not, of course. But I just want to say that there are various techniques for unit testing data layer, abstract code or web services. There are also some well-documented patterns and practices on how to write your code to make the unit testing process easier.


View Entire Article

User Comments

Title: moncler jackets outelt uk   
Name: hufgfesgfde@yahoo.com
Date: 2012-12-03 2:49:12 AM
Comment:
kateris.bloggospace.de/202597/Different-section-of-moncler-jackets/
kateris.bloggospace.de/202593/the-high-quality-with-burberry-scarf/
http://brokencontrollers.com/teach-you-wear-the-down-jackets-xye123905
http://myfgzone.com/pg/blog/read/205331/fake-burberry-outlet-store-online-sale
http://myfgzone.com/pg/blog/read/205332/moncler-jackets-is-your-better-choice-in-the-cold-winter
http://www.alshuaib.net/elgg/pg/blog/read/738964/moncler-best-choice-in-the-winter
http://www.alshuaib.net/elgg/pg/blog/read/738962/burberry-is-nicely-recognized-brand-name
http://uablues.com/blog.php?user=kafers&blogentry_id=32733
http://uablues.com/blog.php?user=kafers&blogentry_id=32732
http://buzzingnetsite.com/blogs/post/14329
http://www.alshuaib.net/elgg/pg/blog/owner/creays
http://buzzingnetsite.com/blogs/user/coutsd
http://buzzingnetsite.com/blogs/14328
http://www.citihubb.com/member/blog_post_view.php?postId=36889
http://www.citihubb.com/member/blog_post_view.php?postId=36888
http://www.citihubb.com/member/view_blog.php?profile_id=1332
http://www.heart-2-heart-dating.com/member/blog_post_view.php?postId=11581
http://www.heart-2-heart-dating.com/member/blog_post_view.php?postId=11580
http://www.freakazoydz.com/member/blog_post_view.php?postId=56631
http://www.freakazoydz.com/member/blog_post_view.php?postId=56630
http://ipayforward.org/member/blog_post_view.php?postId=39537
http://ipayforward.org/member/blog_post_view.php?postId=39536
Title: knock off burberry scarf   
Name: hufgfesgfde@yahoo.com
Date: 2012-12-03 2:48:34 AM
Comment:
http://allmyart.socialgo.com/members/profile/55/blog-view/burberry-totes-is-only-great---real_646.html
http://kafdgfe.setfa.ir/1391/09/12/classy-burberry-outlet-online/
http://ir-plc.ir/blog/brandsales/1391/09/12/luxury-burberry-outlet-store-online-sale/
http://kafdgfe.setfa.ir/1391/09/12/moncler-gamme-bleu-2012/
http://ir-plc.ir/blog/brandsales/1391/09/12/cold-winter-warm-moncler/
http://allmyart.socialgo.com/members/profile/55/blog-view/the-boom-of-moncler-jackets_647.html
http://saleses.blog.sohu.com/247349327.html
http://saleses.blog.sohu.com/247349192.html
http://mak430.net/bbpress/topic.php?id=193575
http://www.discoveryunknown.com/members/profile/1608/blog-view/replica-burberry-outlet-store-online-sale_20430.html
http://www.discoveryunknown.com/members/profile/1608/blog-view/teach-you-wear-the-down-jackets_20431.html
http://mak430.net/bbpress/topic.php?id=193581
http://dinowap.ru/blog.php?user=okalehs&blogentry_id=8085
http://dinowap.ru/blog.php?user=okalehs&blogentry_id=8084
http://weareninety.com/blog.php?user=leough&blogentry_id=920413
http://weareninety.com/blog.php?user=leough&blogentry_id=920390
http://ecomport.net/blog.php?user=garker&blogentry_id=73528
http://ecomport.net/blog.php?user=garker&blogentry_id=73527
http://ihopeihope.com/forum/topic/39
http://ihopeihope.com/forum/topic/40
http://brokencontrollers.com/be-a-handsome-man-you-need-the-burberry-scarves-xye123904
http://www.authorcraftblog.co.uk/blog_entry.php?user=okalehs&blogentry_id=1206551
http://www.authorcraftblog.co.uk/blog_entry.php?user=okalehs&blogentry_id=1206539
Title: http://www.michaelkorsoutletsonline.org/   
Name: Ralph Lauren Outlet
Date: 2012-11-26 6:42:49 AM
Comment:
http://www.poloralphlaurenoutletsonline.org/ Ralph Lauren Outlet
http://www.michaelkorsoutletsonline.org/ michael kors outlet
Title: Offshore Web Application Development   
Name: Domnik Desoja
Date: 2012-11-19 6:10:04 AM
Comment:
Too much informative blog.You have post all details about .net and MVC.
Thanks
omniesolutions.com
Title: http://www.burberryoutletonlines.us/   
Name: Ralph Lauren Outlet
Date: 2012-09-26 1:43:42 AM
Comment:
http://www.ralphlaurenoutletonlines.co.uk/ Ralph Lauren Outlet
http://www.burberryoutletonlines.us/ Burberry Outlet
Title: ASP.NET Developer   
Name: Cheryl Ray
Date: 2012-09-06 2:55:28 AM
Comment:
The tutorial you have explained in the blog is really amazing. I must say you have covered each and every aspect which comes in ASP.NET developer mind when comes to building Blog Engine using the mentioned technology.
Title: How can i find the part-5 of this series ?   
Name: Vu.Lam
Date: 2012-08-11 2:45:53 AM
Comment:
I'v been reading this series from the 1st series. It's really healpful. I'v been trying to search for the 5-part. Where can i find it ?
Thanks a bundle
Title: Entire article the images are not shown   
Name: Skull Kid
Date: 2012-08-10 4:34:13 AM
Comment:
Hi,

I have been reading your article and planning on working on it. Can you kindly make sure the image links wont be broken. Its a great piece of work and it is helping me so much. I wish it does benefit many like me.
Title: burberry outlet   
Name: burberry outlet
Date: 2012-07-27 11:03:13 PM
Comment:
Well, if the circumstances are very intense, the story is very moving, the character very vivid, the truth is very deep, I saw very moved. Such a good article is worth my attention, and I think will pay more attention to is should, but also can increase my knowledge.
Title: 2012 NFL jerseys   
Name: NIKE NFL jerseys
Date: 2012-05-20 11:39:17 PM
Comment:
[/pre]Cheap NFL,NBA,MLB,NHL
[url=http://www.jersey2shop.com/]Jerseys From China[/url]
[url=http://www.jersey2shop.com/]2012 nike nfl Jerseys[/url]
[url=http://www.jersey2shop.com/]cheap China Jerseys[/url]
[url=http://www.jersey2shop.com/]Sports Jerseys China[/url]
[url=http://www.jersey2shop.com/NFL-Jerseys-c68/]NFL Jerseys China[/url]
[url=http://www.jersey2shop.com/NBA-Jerseys-c77/]NBA Jerseys China[/url]
NHL Jerseys China
[url=http://www.jersey2shop.com/MLB-Jerseys-c94/]MLB Jerseys China[/url]NFL jerseys For Sale online.All Our Jerseys Are Sewn On and Directly From Chinese Jerseys Factory
[/pre]
[pre]We Are Professional China jerseys Wholesaler
[url=http://www.cheapjersey2store.com/]Wholesale cheap jerseys[/url]Cheap mlb jerseys
[url= http://www.cheapjersey2store.com/]2012 mlb all atar jerseys[/url]
[url= http://www.cheapjersey2store.com/ [/url]Cheap China Wholesael[/url]
[url= http://www.cheapjersey2store.com/]Wholesale jerseys From China[/url]
[url=http://www.cheapjersey2store.com/]2012 nike nfl Jerseys[/url]Free Shipping,Cheap Price,7 Days Deliver
[/pre]
[/pre]
We are professional jerseys manufacturer from china,wholesal
sports [url= http://www.cheapjersey2store.com/]Jerseys From China[/url]
[url=http://www.cheapjersey2store.com/NFL-Jerseys-c68]NFL jerseys China[/url]
[url=http://www.cheapjersey2store.com/NHL-Jerseys-c96/]NHL Jerseys China[/url]
[url=http://www.cheapjersey2store.com/NBA-Jerseys-c77/]NBA Jerseys China[/url]
[url=http://www.cheapjersey2store.com/MLB-Jerseys-c94/]MLB Jerseys China[/url]
[url= http://www.cheapjersey2store.com/]China Jerseys[/url],Free Shipping
[/pre]
[/pre]
We are professional jerseys manufacturer from china,wholesal
sports [url= http://www.jerseycaptain.com/]cheap jerseys sale online [/url]
[url= http://www.jerseycaptain.com/]2012 nike nfl Jerseys[/url]
[url=http://www.jerseycaptain.com/NFL-Jerseys-c68]cheap NFL jerseys China[/url]
[url=http://www.jerseycaptain.com/NHL-Jerseys-c96/]NHL Jerseys C
Title: Filipino chat Room   
Name: Rekoyan
Date: 2011-09-06 9:02:47 PM
Comment:
Come visit the Filipino Chat Community www.chat.ph it is the live chat community for the Philipines
Title: merawakil   
Name: alice john
Date: 2010-10-18 6:18:14 AM
Comment:
The ASP.NET methodology has been a huge leap in the way web applications are developed and deployed. Previously in traditional ASP, code was cluttered and there was no clear and simplified way in which the benefits of object oriented programming could be brought to the web. In addition, there was no clear separation between the presentation layer and business logic, making maintenance of code a big issue.
Title: This is one of my favorite website. I like the information that is being share. Thanks a lot.   
Name: pacquiao vs margarito online
Date: 2010-10-06 4:48:37 PM
Comment:
This is one of my favorite website. I like the information that is being share. Thanks a lot.
Title: Mark S. is definitely on the right track. If you want to get a professional looking email address, Id recommend buying your name domain name, like or   
Name: vibram fivefingers
Date: 2010-09-13 9:56:10 PM
Comment:
Mark S. is definitely on the right track. If you want to get a professional looking email address, Id recommend buying your name domain name, like or
If its common it might be difficult to get, however, be creative and you can usually find something.
Title: Colorado Business Immigration   
Name: Colorado Business Immigration
Date: 2010-09-10 12:50:01 PM
Comment:
hi very nice article i got a lot of information from it.
thompson44
Title: Thanks for the very nice info. It is really useful.   
Name: pacquiao vs margarito
Date: 2010-08-21 10:40:12 AM
Comment:
Thanks for the very nice info. It is really useful.
Title: Offshore ASP.net Web programmers   
Name: ashokpatidar89@gmail.com
Date: 2010-06-17 2:26:12 AM
Comment:
Awesome!

I enjoyed it!

Thanks!
Title: Authentic Designer Handbags   
Name: john mite
Date: 2010-05-13 6:32:30 AM
Comment:
Thanks for taking the time to share this, I feel strongly about it and love reading more on this topic. It is extremely useful for me.
Title: Yachtcharter Griechenland   
Name: pramod.singh.sv@gmail.com
Date: 2010-04-15 2:39:29 AM
Comment:
I was just thinking about Building a Simple Blog Engine with ASP.NET MVC and LINQ - Part 4 and you've really helped out. Thanks!
Title: Writing Assignment Help   
Name: Writing Assignment Help
Date: 2010-03-19 8:57:49 AM
Comment:
Your blog provides us a very great information. Its really very helpful to me to find result on search engine. Hope to hear more good information related to searching from your side.
Title: nice blog i learn a lot from it. Thanks for sharing. regards, rosela   
Name: Watch Pacquiao Vs Clottey Live online
Date: 2010-03-09 6:43:14 PM
Comment:
nice blog i learn a lot from it.
Thanks for sharing.

regards,

rosela
Title: blog hopping...nice blog   
Name: Webthesurfi Rugs Webdesign
Date: 2010-03-09 6:40:17 PM
Comment:
blog hopping...nice blog
Title: first step   
Name: swarovski for men
Date: 2010-03-08 3:47:14 AM
Comment:
Its first time here i found its very nice and informative blog. Thanks for sharing this useful post with us. i wanna to be here very often. I am going to check this site for more details
Title: your blog is very imformative and i learn a lot from it. Thanks for sharing. regards, rosela   
Name: Watch Pacquiao Vs Clottey Live
Date: 2010-02-25 9:15:22 PM
Comment:
your blog is very imformative and i learn a lot from it.
Thanks for sharing.

regards,

rosela
Title: very entertaining and informative blog. Ill be back..   
Name: Webthesurfi Rugs Webdesign
Date: 2010-02-25 7:37:42 PM
Comment:
very entertaining and informative blog. Ill be back..
Title: wow..i love reading your blog. i'll be back soon..   
Name: Sikat ang Pinoy
Date: 2010-02-12 5:01:11 PM
Comment:
wow..i love reading your blog. i'll be back soon..
Title: sikat ang pinoy   
Name: renantech@yahoo.com
Date: 2010-01-29 8:40:21 PM
Comment:
I like blogengine.net powered by asp.net because this is the free technology that i can create modern website for my personal use or for business use. I would like to thank you for sharing your thoughts and time into the stuff you post!! Thumbs up!
Title: hii   
Name: s
Date: 2009-10-19 12:51:50 AM
Comment:
nice work..
Title: Busby SEO Test   
Name: ranelyn_castro@yahoo.com
Date: 2008-11-29 12:30:54 AM
Comment:
What a nice post about Building a Simple Blog Engine with ASP.NET MVC and LINQ
Title: Source code?   
Name: James
Date: 2008-10-31 12:21:35 PM
Comment:
Great article! where is the source code?
Title: Outstanding article!ank you!   
Name: Ryan
Date: 2008-10-11 5:53:56 PM
Comment:
Outstanding article Keyvan! I would love to see the completed blog. I realize there have been some changes to the framework but, the views would be a very caluable post.

Th
Title: Nice   
Name: Nano
Date: 2008-07-25 12:56:14 PM
Comment:
I can't wait any more... Next part plz!
Title: Kblog View   
Name: Shaurav
Date: 2008-07-22 12:41:55 PM
Comment:
When are you going to publish the next part of it where you are going to talk about Views
Title: KBlog DEMO   
Name: Jame
Date: 2008-06-19 10:35:05 PM
Comment:
Can you provide the KBlog DEMO download address?
Title: MVC   
Name: Asmi
Date: 2008-06-09 5:24:51 AM
Comment:
Nice Article!! Waiting for the next to implement these practically.........
Title: MVC   
Name: Basheer Ahmed
Date: 2008-05-17 2:58:30 PM
Comment:
trp to put all series in one pdf file format
Title: sweet   
Name: Johan
Date: 2008-05-13 3:59:36 PM
Comment:
Nice article, looking forward for the next one.

Product Spotlight
Product Spotlight 





Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2017 ASPAlliance.com  |  Page Processed at 2017-08-18 10:30:06 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search