Skip to content

Commit ba62291

Browse files
committed
Skip tests faster if SQL Server not available.
1 parent b6341a2 commit ba62291

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/IntelliTect.AspNetCore.SignalR.SqlServer.Tests/SqlServerEndToEndTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class SqlServerEndToEndTests
1616
{
1717
private const string databaseName = "SignalRUnitTestsDb";
1818
private const string connectionString =
19-
"Server=localhost;Database=" + databaseName + ";Trusted_Connection=True;";
19+
"Server=localhost;Database=" + databaseName + ";Trusted_Connection=True;Timeout=5";
2020

2121
[SkippableFact]
2222
public async Task CanSendAndReceivePayloads_WithServiceBroker()
@@ -99,7 +99,7 @@ private static async Task CreateDatabaseAsync()
9999
|| ex.Message.Contains("The server was not found or was not accessible")
100100
)
101101
{
102-
Skip.If(true, "SQL Server not available on localhost");
102+
Skip.If(true, ex.Message);
103103
}
104104
}
105105
}

0 commit comments

Comments
 (0)