test driven development using visual studio team system ariel gur-arieh vp r&d – mcd software...

Post on 24-Dec-2015

220 Views

Category:

Documents

1 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Test Driven Development Test Driven Development using using

Visual Studio Team SystemVisual Studio Team SystemAriel Gur-AriehVP R&D – MCD Software Solutionshttp://blogs.microsoft.co.il/blogs/arielga

AgendaAgenda

• Challenges we deal today• Unit Testing• Database can be Unit Tested!• Be Agile - Test Driven Development• Q&A• Summary

Challenges we deal todayChallenges we deal today

• Does our code do what we intended?• Documentation – is it updated?• Debug – again?• Change Request – no sleep, again!?!• Customers speak Gibberish, translation

please.

Unit TestUnit Test

Parts of the code behaves as intended.

DEMODEMOUnit Test using Visual Studio.

Code CoverageCode Coverage

Which code has been touched by a test.

DEMODEMOCode Coverage Using Team System.

Database can be Unit Tested!Database can be Unit Tested!

User Interface

ApplicationCode

UnitTests

Data Access Layer

Stored Procedures

DEMODEMODatabase Unit Testing.

Get Agile – Test Driven Get Agile – Test Driven DevelopmentDevelopment

Tools For Agility, Kent BeckTools For Agility, Kent Beck

Practices

Tools

Test Driven DevelopmentTest Driven DevelopmentThe motto "Red, Green, Refactor ".

DEMODEMOChanging code in TDD.

TDD in Action: Active BugTDD in Action: Active BugBug: Expired Credit Cards are being Credited

DEMODEMOAdding code in TDD.

TDD in Action: New RequirementTDD in Action: New RequirementRequirement: Add Bonuses to special customers.

Quality IndicatorsQuality Indicators

Iteration 1 Iteration 3 Iteration 4 Iteration 5Iteration 2

91

20

51

76

60

56

19

18

40

71

80

32.5

12

8

9

Benefits of Test Driven Benefits of Test Driven DevelopmentDevelopment

Benefits of Test Driven Benefits of Test Driven DevelopmentDevelopment

$59,000,000,000

TDD - Application LifecycleTDD - Application Lifecycle

Development and testing/bug fixing take about the same amount of timeDevelopment takes more time than testing, and testing time is reduced Overall lifecycle is shortened

Unit testing is a learned skill Unit testing is a learned skill that can only be honed with that can only be honed with experience.experience.

Starting Test Driven DevelopmentStarting Test Driven Development

Creating a cultural change is hard…Creating a cultural change is hard…

…….. and it can be .. and it can be done.done.

Q & AQ & A

SummarySummary

• Development becomes more challenging.• Unit Test create a safety net.• Database can be Unit Tested!• Documentation is the best side effect ever!• Development is Faster using TDD.• VSTS is a great tool for UT and TDD.

THANK YOUTHANK YOU

Additional ResourcesAdditional Resources• Visual Studio Team System 2008 - Trial Software

http://msdn.microsoft.com/en-gb/vsts2008/products/cc268310.aspx

• MSDN - Working with Unit Testshttp://msdn.microsoft.com/en-us/library/ms182515.aspx

• Guidelines for Test-Driven Developmenthttp://msdn.microsoft.com/en-us/library/aa730844.aspx

Related SessionsRelated SessionsALM301: Web Sites Testing with Visual Studio Team SystemShai Raiten10:50-12:00 Arava Hall

ALM303: Professional Developer Tools in Visual Studio…Maor David10:50-12:00 Tavor Hall

DEV314: Design Patterns – Learn From the Experience… Avi Roth14:30-15:40 Galil Hall

© 2008 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after

the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

top related