There is no single, correct approach to developing and testing your SQL batches and routines. It depends on the requirement. For simple tasks, like modifying and testing a view or stored procedure, SQL Compare and SQL Data Generator, combined, provide a useful, lightweight development harness. Read more
A PowerShell automation script to build a SQL Server database from source control, seed it with dummy data, document it, and then deploy copies to any number of test and development servers. Read more