Web Application Fundamentals — Part 3

In part one of this article, I focused on what Model-View-Controller (MVC) is and how it applies to web application development. Also in Part two, I gave a simplified introduction to Object Oriented Programming. In this section am going to be talking about Test Driven Development (TDD).

What is test driven development ?

Test driven development (TDD) is a kind of development practice that believes in testing fragments of code before integration into larger system. The tested code section is integrated if and only if it pass the test conditions. A mother, cooking a soup for the family, will be tasting bits of the soup and making adjustments as necessary, so that the final cooked soup will be tasty and delicious to the whole family. The same thinking is applied to test driven development. Execute code snippets or sections against certain conditions in a test environment. If the test fails, it means it will fail in production so refactor and test again, until the test pass. That is why before you begin to write thousands of lines of code first test them in bits and units (Unit Testing).

Isn’t it time wasting? Well, imagine you have developed an e-commerce web site without testing. By the time you execute the program, you are likely going to spend the remaining working hours if not days correcting simple mistakes and logical errors. So in real sense, it doesn’t waste time at all rather it saves time. Another advantage of testing is early error detection and correction when it’s least expensive.

Executing code without testing source: http://relax4bro.com/image/show/20258
Test Frameworks

There are quite a number of frameworks out there that make testing your application possible and easy and have automate the process for you. Below is a simple list of test frameworks and tools:

Note that how to use each of the test frameworks is beyond the scope of this article. All I want to do is to answer the question what is test driven development and relates it to Web Application Development. Materials abound on the internet to take you to the next level of testing your web applications.

Thanks for reading! kindly recommend this post (by clicking the ❤ button) so other people can find it. Got questions, contributions or want to write for us, let’s hear them at the comment section below. You can always say hello to the Author — Seun Matt
Developer? Join our slack channel here. Got a project idea and need a team of experts? Say hello to us via hello@prodsters.com to get started.
Show your support

Clapping shows how much you appreciated Seun Matt’s story.