public void Test_ColourMatrix_Determinant() { new ColourMatrix(1, 2, 3, 4, 5, 6, 7, 8, 9).Determinant.Should().Be(0); new ColourMatrix(1, 2, 6, 3, 9, 4, 7, 8, 5).Determinant.Should().Be(-195); new ColourMatrix(1, 2, 3, 2, 3, 4, 4, 2, 1).Determinant.Should().Be(-1); var m = new ColourMatrix(1, 2, 3, 2, 3, 4, 4, 2, 1); m.Determinant.Should().Be(-1); m.Determinant.Should().Be(-1, "should be cached when requested a second time"); }
public void Test_ColourMatrix_Construction() { var m = new ColourMatrix(1, 2, 3, 4, 5, 6, 7, 8, 9); m.M11.Should().Be(1); m.M12.Should().Be(2); m.M13.Should().Be(3); m.M21.Should().Be(4); m.M22.Should().Be(5); m.M23.Should().Be(6); m.M31.Should().Be(7); m.M32.Should().Be(8); m.M33.Should().Be(9); }
public static ColourMatrixAssertions Should(this ColourMatrix value) => new ColourMatrixAssertions(value);