Skip to content

Commit

Permalink
Add tests for FallbackTestFramework and AssertionFailedException
Browse files Browse the repository at this point in the history
  • Loading branch information
lg2de committed Dec 7, 2022
1 parent 95fb4c4 commit cfba009
Showing 1 changed file with 24 additions and 0 deletions.
@@ -0,0 +1,24 @@
using FluentAssertions.Execution;
using Xunit;

namespace FluentAssertions.Specs.Execution;

public class FallbackTestFrameworkTests
{
[Fact]
public void When_accessing_fallback_test_framework_it_is_always_available()
{
var sut = new FallbackTestFramework();

sut.IsAvailable.Should().BeTrue();
}

[Fact]
public void When_using_fallback_test_framework_the_correct_exception_is_thrown()
{
var sut = new FallbackTestFramework();

sut.Invoking(x => x.Throw("test message")).Should().ThrowExactly<AssertionFailedException>()
.WithMessage("test message");
}
}

0 comments on commit cfba009

Please sign in to comment.