public void Should_Throw_If_Output_File_Is_Null() { // Given var fixture = new DotCoverReporterFixture(); fixture.OutputFile = null; // When var result = Record.Exception(() => fixture.Run()); // Then Assert.IsArgumentNullException(result, "outputFile"); }
public void Should_Throw_If_Settings_Are_Null() { // Given var fixture = new DotCoverReporterFixture(); fixture.Settings = null; // When var result = Record.Exception(() => fixture.Run()); // Then Assert.IsArgumentNullException(result, "settings"); }
public void Should_Append_ConfigurationFile() { // Given var fixture = new DotCoverReporterFixture(); fixture.Settings.WithConfigFile(new FilePath("./config.xml")); // When var result = fixture.Run(); // Then Assert.Equal("Report \"/Working/config.xml\" " + "/Source=\"/Working/result.dcvr\" " + "/Output=\"/Working/result.xml\"", result.Args); }
public void Should_Append_LogFile() { // Given var fixture = new DotCoverReporterFixture(); fixture.Settings.LogFile = "./logfile.log"; // When var result = fixture.Run(); // Then Assert.Equal("Report " + "/Source=\"/Working/result.dcvr\" " + "/Output=\"/Working/result.xml\" " + "/LogFile=\"/Working/logfile.log\"", result.Args); }
public void Should_Append_ReportType(DotCoverReportType reportType, string reportTypeString) { // Given var fixture = new DotCoverReporterFixture(); fixture.Settings.ReportType = reportType; // When var result = fixture.Run(); // Then Assert.Equal("Report " + "/Source=\"/Working/result.dcvr\" " + "/Output=\"/Working/result.xml\" " + "/ReportType=" + reportTypeString, result.Args); }