public void Control_codes_with_nonequivalent_content_are_not_equal() { var one = new AnsiControlCode($"{Ansi.Esc}[s"); var two = new AnsiControlCode($"{Ansi.Esc}[u"); one.Equals(two).Should().BeFalse(); }
public void Control_codes_with_equivalent_content_are_equal() { var one = new AnsiControlCode($"{Ansi.Esc}[s"); var two = new AnsiControlCode($"{Ansi.Esc}[s"); one.Equals(two).Should().BeTrue(); one.Invoking(code => code.Equals(null)).Should().NotThrow <NullReferenceException>(); }