Example #1
0
        public void ValidationReport_Differs_WarningDifference()
        {
            var reportOne = ValidationReportProvider.GetReport("Test.md", "[Bar](bar.txt)");    // Unresolved
            var reportTwo = ValidationReportProvider.GetReport("Test.md", "[Foo](../bar.txt)"); // OutOfContext

            Assert.NotEqual(reportOne, reportTwo);
        }
Example #2
0
        public void ValidationReport_Differs_WarningLocation()
        {
            var reportOne = ValidationReportProvider.GetReport("Test.md", "[Bar](bar.txt)");
            var reportTwo = ValidationReportProvider.GetReport("Test.md", " [Bar](bar.txt)");

            Assert.NotEqual(reportOne, reportTwo);
        }
Example #3
0
        public void ValidationReport_Differs_WarningCount()
        {
            var reportOne = ValidationReportProvider.GetReport("Test.md", string.Empty);
            var reportTwo = ValidationReportProvider.GetReport("Test.md", "Foo");

            Assert.NotEqual(reportOne, reportTwo);
        }
Example #4
0
        public void Warning_Equals()
        {
            var reportOne = ValidationReportProvider.GetReport("Test.md", "[Bar](bar.txt)");
            var reportTwo = ValidationReportProvider.GetReport("Test.md", "[Foo](bar.txt)");

            var warningOne = reportOne.WarningsByFile.Single().Value.Single();
            var warningTwo = reportTwo.WarningsByFile.Single().Value.Single();

            Assert.NotSame(warningOne, warningTwo);
            Assert.Equal(warningOne, warningTwo);
        }