public void When_a_property_throws_it_does_not_prevent_other_properties_from_being_written()
            {
                var log = new SomePropertyThrows().ToDisplayString();

                log.Should().Contain("Ok:");
                log.Should().Contain("Fine:");
                log.Should().Contain("PerfectlyFine:");
            }
示例#2
0
            public void It_displays_exceptions_thrown_by_properties_in_the_property_value_cell()
            {
                var formatter = HtmlFormatter.GetBestFormatterFor(typeof(SomePropertyThrows));

                var writer = new StringWriter();

                var widget = new SomePropertyThrows();

                formatter.Format(widget, writer);

                writer.ToString()
                .Should()
                .Contain("<td>{ System.Exception:");
            }
            public void When_a_property_throws_then_then_exception_is_written_in_place_of_the_property()
            {
                var log = new SomePropertyThrows().ToDisplayString();

                log.Should().Contain("NotOk: { System.Exception: ");
            }