Skip to content

Commit a824b4a

Browse files
author
Bart Koelman
authored
Rewrite flaky tests using new infrastructure (#856)
This change affects solely the test implementations, without changing their names or what they assert on. Both need improvements, but are not in scope of this effort.
1 parent f72615f commit a824b4a

File tree

5 files changed

+357
-367
lines changed

5 files changed

+357
-367
lines changed

test/JsonApiDotNetCoreExampleTests/Acceptance/Extensibility/CustomErrorHandlingTests.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System;
2+
using System.Linq;
23
using System.Net;
34
using JsonApiDotNetCore.Configuration;
45
using JsonApiDotNetCore.Errors;
@@ -29,8 +30,8 @@ public void When_using_custom_exception_handler_it_must_create_error_document_an
2930
Assert.NotEmpty((string[]) errorDocument.Errors[0].Meta.Data["StackTrace"]);
3031

3132
Assert.Single(loggerFactory.Logger.Messages);
32-
Assert.Equal(LogLevel.Warning, loggerFactory.Logger.Messages[0].LogLevel);
33-
Assert.Contains("Access is denied.", loggerFactory.Logger.Messages[0].Text);
33+
Assert.Equal(LogLevel.Warning, loggerFactory.Logger.Messages.Single().LogLevel);
34+
Assert.Contains("Access is denied.", loggerFactory.Logger.Messages.Single().Text);
3435
}
3536

3637
public class CustomExceptionHandler : ExceptionHandler

test/JsonApiDotNetCoreExampleTests/Acceptance/Spec/EndToEndTest.cs

Lines changed: 0 additions & 102 deletions
This file was deleted.

0 commit comments

Comments
 (0)