feat(batch50): merge JetStream cluster 1 tests and fix build errors
- Added ShouldSkip() and ServerRuntimeUnavailable to IntegrationTestBase - Fixed WaitOnPeerCount -> WaitOnClusterReady - Fixed using -> await using for NatsConnection (IAsyncDisposable) - Removed duplicate PackageReference entries from csproj
This commit is contained in:
@@ -45,6 +45,19 @@ public abstract class IntegrationTestBase : IDisposable
|
||||
/// <summary>xUnit output helper, available to derived test classes.</summary>
|
||||
protected ITestOutputHelper Output { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Returns true if integration tests should be skipped.
|
||||
/// Convenience method for use in individual test methods that call
|
||||
/// <c>Skip.If(ShouldSkip(), "reason")</c>.
|
||||
/// </summary>
|
||||
protected static bool ShouldSkip() => !Helpers.TestServerHelper.CanBoot();
|
||||
|
||||
/// <summary>
|
||||
/// Returns true if the server runtime is unavailable.
|
||||
/// Alias for <see cref="ShouldSkip"/> used by some test batches.
|
||||
/// </summary>
|
||||
protected static bool ServerRuntimeUnavailable => !Helpers.TestServerHelper.CanBoot();
|
||||
|
||||
// =========================================================================
|
||||
// IDisposable
|
||||
// =========================================================================
|
||||
|
||||
Reference in New Issue
Block a user