Isaac Levin
Isaac Levin

Reputation: 2909

SQL Server Unit Test Project template missing

I am looking to implement Unit Testing of a database project I have created following this tutorial

http://blogs.msdn.com/b/ssdt/archive/2012/12/07/getting-started-with-sql-server-database-unit-testing-in-ssdt.aspx?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+ssdtblog+(SQL+Server+Developer+Tools+Team+Blog)

I have Visual Studio 2012 Ultimate Installed, and the latest update for SSDT, but I do not have the SQL Server Test Project Template available in Visual Studio. If I go to Templates, than Visual C#, the SQL Server folder only contains SQL Server Database Project. What do I need to do to configure the SQL Server Test Project?

Upvotes: 0

Views: 1828

Answers (1)

Steven Green
Steven Green

Reputation: 3517

Database unit tests in VS2012 and VS2013 just use the standard unit test project, like so:

  1. Right-click on your solution and choose Add > New Project...
  2. In the Add New Project dialog, select Visual C# > Test > Unit Test Project, enter a name and click OK.
  3. In Solution Explorer, right click on the new unit test project and choose Add > New Item...
  4. In the Add New Item dialog, select SQL Server > SQL Server Unit Test.

It's also possible to right-click on a stored procedure, etc. in SQL Server Object Explorer and choose Create Unit Test.

Upvotes: 3

Related Questions