Test Driven Development (TDD) in Software Development
Test Driven Development (TDD) is a valuable practice in software development that involves creating unit test cases before writing code to ensure better quality, reduce development time, and align with Agile methodologies. Learn about the phases of TDD, advantages it offers, and how it fits into Agile development.
Download Presentation

Please find below an Image/Link to download the presentation.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.
You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.
The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.
E N D
Presentation Transcript
TEST DRIVEN DEVELOPMENT DRIVEN DEVELOPMENT PPT by - ADIBA QAZI
THE OLD SCHOOL APPROACH SCHOOL APPROACH NEW SCHOOL APPROACH NEW SCHOOL APPROACH
Test Driven Development (TDD) is a software development practice that focuses on creating unit test cases before developing the actual code.It is an iterative approach that combines programming, the creation of unit tests, and refactoring. 3 Phases of Test Driven Development :-- 1) Create Precise Tests - Developers need to create precise unit tests to verify the functionality of specific features. 2) Correcting The Code -Once a test fails, developers need to make the minimal changes. 3) Refactor The Code -Once the test runs successfully, check for redundancy or any possible code optimizations.
Frameworks for Test Driven Development Based on unique programming languages, there are multiple frameworks that support test driven development, these are:-- 1) csUnit and NUnit Both are open source unit testing frameworks for .NET projects. 2) PyUnit and DocTest - Popular Unit testing framework for Python. 3) Junit - Widely used unit testing tool for Java. 4) TestNG - Another popular Java testing framework. This framework overcomes the limitations of Junit. 5) Rspec - A testing framework for Ruby projects.
How TDD fits into Agile development?b Agile Development demands regular feedback to develop the expected product, therefore, is also termed as Feedback Driven Development. There s a high probability that project requirements may change during the development sprint cycle. To deal with this and to build products aligned with the client s changing requirements, we need constant feedback to avoid unusable software. TDD is built to offer this feedback at the earliest.
ADVANTAGES OF TDD 1. Better program design,higher code quality - Developers write the necessary tests, and the code, to avoid all the failures. Consequently, the code appears to give better results. Test Driven Development (TDD) is a software development practice that focuses on creating unit test cases before developing the actual code requirements, includes all the likely users actions. 2. Detailed project documentation -writing tests for particular 3. It reduces the time required for project development - when tests fail,where they should pass,developers understand immediately ,therefore it saves time during project development phase.
continued ... 4. High test coverage -There s a test for each feature. 5. With TDD we will get a reliable solution - Tests help to understand if everything goes right after adding a new feature. 6. Save project costs in the long run - Quality of the project will significantly be higher. 7. Reduction in bugs - Since we are doing test first,so fewer bugs, hence we will spend less time to fix them. 8. Avoids duplication of code.
DISADVANTAGES OF TDD 1. Early Test cases created ,are heavy in maintenance. 2. Tend to write test cases which may not be needed. 3. Creating Test cases for failures can be tedious. 4. Requirement changes is paid.
Statistics showing costs of code maintenance created without TDDtics showing costs of code maintenance created without TDD.
THANK YOU THANK YOU!