Automated and Repeatable Test Cases for SQL Server Development Stefan Riedel |
Housekeeping Mobile Phones Evaluations Time
Stefan Riedel Working with MS SQL Server for more than 16 years. Data Warehouse and Business Intelligence solutions. Waterfall and Agile Development Methodologies. http://au.linkedin.com/pub/stefan-riedel/8/27/59b/ stefan-riedel@outlook.com
Automated and Repeatable Test Cases for SQL Server Development Waterfall Agile Manual Automated Although Agile projects need automated testing, all projects need testing.
Test Driven Development Create test then write code to pass test. Unit Testing, Functional Testing, Acceptance Testing. Testing system develops over time.
Software Setup Windows 8.1 Pro SQL Server 2014 Developer Visual Studio 2013 Community Edition -- SQL Server Data Tools (SSDT) included -- Visual Studio 2013 BI Data tools Installed Adventure Works OLTP SSDB on local server Installed Adventure Works OLAP SSDB on local server Installed Adventure Works OLAP SSAS on local server
Story/Requirement Story/Requirement To analyse how people first find out about our company. Tasks Update stored procedures that insert, update or delete fields about a person.
Test Driven Development Demo 10. Write test 20. Run test and see it fail 30. Write code so test will pass 40. Run test and see it pass 50. GOTO 10
Other tests Standards and Best Practice Primary Key on all tables Naming Standards using DMVs
Other tests (Cont.) Linked Server to check SSAS values
What Next? Test SSIS ETL from OLTP DB to OLAP DB. Other possible tests FK relationships Indexes SQL Server properties
What Else? TSQLUnit, tSQLt ssisUnit Redgate, Varigence Cucumber, Specflow .NET