Reputation: 3777
I can't seem to get my tSQLt test to show up in Visual Studio Test Explorer.
I have a database project (SSDT) that contains my database that I want to test against. I also have another database project in the solution that is named the same as the main database project but has .Tests
appended to the end of the name. The .Tests
project contains a database reference to the main database project.
I ran the install script for tSQLt in the database and can see all the stored procedures for tSQLt in the database.
I have installed the tSQLt test adapter extension from Visual Studio's Extensions and Updates dialog. I'm using Visual Studio 2015 Update 3.
I created a .runsettings
file and selected it by going to Test > Test Settings > Select Test Settings File
as the adapter instructions state. Here are the contents of that file (I removed the connection string details in this post but I have verified my connection string works elsewhere):
<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
<TestRunParameters>
<Parameter name="TestDatabaseConnectionString" value="Server=MySqlServer;Initial Catalog=MyDatabase;Integrated Security=SSPI" />
<Parameter name="IncludePath" value="Tests" />
</TestRunParameters>
</RunSettings>
When I build the solution, I don't see any tests in the Test Explorer window. Any ideas on what I can try to fix this?
Upvotes: 1
Views: 1040
Reputation: 3777
I'm not sure what I was doing wrong before, but I created the projects again from scratch and everything is working now.
Upvotes: 1