public void Should_Read_Issue_Without_File_Correct() { // Given var fixture = new MsBuildIssuesProviderFixture("IssueWithoutFile.xml"); // When var issues = fixture.ReadIssues().ToList(); // Then issues.Count.ShouldBe(1); var issue = issues.Single(); CheckIssue( issue, null, null, "CA1711", 0, "Microsoft.Naming : Rename type name 'UniqueQueue(Of T)' so that it does not end in 'Queue'."); }
public void Should_Read_Issue_With_File_Without_Path_Correct() { // Given var fixture = new MsBuildIssuesProviderFixture("IssueWithOnlyFileName.xml"); // When var issues = fixture.ReadIssues().ToList(); // Then issues.Count.ShouldBe(1); var issue = issues.Single(); CheckIssue( issue, @"src\Cake.Issues.MsBuild.Tests\MsBuildIssuesProviderTests.cs", 13, "CS0219", 0, "The variable 'foo' is assigned but its value is never used"); }
public void Should_Read_Issue_With_Line_Zero_Correct() { // Given var fixture = new MsBuildIssuesProviderFixture("IssueWithLineZero.xml"); // When var issues = fixture.ReadIssues().ToList(); // Then issues.Count.ShouldBe(1); var issue = issues.Single(); CheckIssue( issue, @"SHFB", null, "BE0006", 0, @"Unable to locate any documentation sources for 'c:\Source\Cake.Prca\Cake.Prca..csproj' (Configuration: Debug Platform: AnyCPU)"); }
public void Should_Read_Issue_With_File_Correct() { // Given var fixture = new MsBuildIssuesProviderFixture("IssueWithFile.xml"); // When var issues = fixture.ReadIssues().ToList(); // Then issues.Count.ShouldBe(1); var issue = issues.Single(); CheckIssue( issue, @"src\Cake.Issues.MsBuild.Tests\MsBuildIssuesProviderTests.cs", 1311, "CA2201", 0, @"Microsoft.Usage : 'ConfigurationManager.GetSortedConfigFiles(String)' creates an exception of type 'ApplicationException', an exception type that is not sufficiently specific and should never be raised by user code. If this exception instance might be thrown, use a different exception type."); }