Skip to content

Instantly share code, notes, and snippets.

@GeeWee
Created June 15, 2020 10:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GeeWee/9f3886b9db97efeebe1e0cbe0d87d443 to your computer and use it in GitHub Desktop.
Save GeeWee/9f3886b9db97efeebe1e0cbe0d87d443 to your computer and use it in GitHub Desktop.
FluentAssertions ShouldBeEquivalentTo
using System.Collections.Generic;
using FluentAssertions;
using Xunit;
namespace AIP.FastlogFG.Test
{
public class FooTest
{
[Fact]
public void foo()
{
// Arrange
var foos = new List<Foo>
{
new Foo()
{
Name = "test"
}
};
var bars = new List<Bar>
{
new Bar()
{
Name = "test"
}
};
foos.Should().BeEquivalentTo(bars);
}
}
public class Foo
{
public string Name { get; set; } = "";
}
public class Bar
{
public string Name { get; set; } = "";
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment