Files
advent-of-code-2023/02/CubeConundrum.Tests/ResultTests.cs
T

23 lines
547 B
C#
Raw Normal View History

namespace CubeConundrum.Tests;
public class ResultTests
{
[Fact]
public void CountProperties_GivenAResult_ItShouldReturnTheCorrectCount()
{
var result = new Result
{
Cubes =
{
new() { Count = 4, Color = CubeColor.Red },
new() { Count = 1, Color = CubeColor.Green },
new() { Count = 2, Color = CubeColor.Blue }
}
};
result.TotalCubeCount.Should().Be(7);
result.RedCubeCount.Should().Be(4);
result.GreenCubeCount.Should().Be(1);
result.BlueCubeCount.Should().Be(2);
}
}