To add a new test
1. In Database Explorer, right-click the database or database object and select Unit Test > Add New Test.
Alternatively, on the Database, select Add New Test.
2. In the Add New Test dialog that opens, specify a connection and database for the test to be created on.
3. In the Test Name box, enter the name for the new test.
Note
If you want to create a new test with a name that already exists, Unit Test displays the Test creation failed warning message informing that there is already an object with the same name in the database.
4. In the Class Name box, specify a class to which the new test should be added.
Note
A test class is a special schema configured to include one or more related tests.
6. Click Add Test.
7. The test has been created. Unit Test opens a query template for you to fill up using regular T-SQL.
Download dbForge Studio for SQL Server and try it absolutely free for 30 days!