Set console-logger output to normal
This commit is contained in:
parent
44100209bc
commit
67142bfd5d
4 changed files with 7 additions and 6 deletions
|
@ -19,6 +19,7 @@ namespace Microsoft.DotNet.Tools.Test.Utilities
|
||||||
{
|
{
|
||||||
protected const string DefaultFramework = "netcoreapp1.0";
|
protected const string DefaultFramework = "netcoreapp1.0";
|
||||||
protected const string DefaultLibraryFramework = "netstandard1.5";
|
protected const string DefaultLibraryFramework = "netstandard1.5";
|
||||||
|
protected const string ConsoleLoggerOutputNormal = "--logger:console;verbosity=normal";
|
||||||
private TempRoot _temp;
|
private TempRoot _temp;
|
||||||
private static TestAssetsManager s_testsAssetsMgr;
|
private static TestAssetsManager s_testsAssetsMgr;
|
||||||
private static TestAssets s_testAssets;
|
private static TestAssets s_testAssets;
|
||||||
|
|
|
@ -32,7 +32,7 @@ namespace Microsoft.DotNet.Cli.Test.Tests
|
||||||
var result = new DotnetTestCommand()
|
var result = new DotnetTestCommand()
|
||||||
.WithWorkingDirectory(testProjectDirectory)
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
.WithRuntime(runtime)
|
.WithRuntime(runtime)
|
||||||
.ExecuteWithCapturedOutput();
|
.ExecuteWithCapturedOutput(TestBase.ConsoleLoggerOutputNormal);
|
||||||
|
|
||||||
result.StdOut
|
result.StdOut
|
||||||
.Should().Contain("Total tests: 3. Passed: 2. Failed: 1. Skipped: 0.", "because .NET 4.6 tests will pass")
|
.Should().Contain("Total tests: 3. Passed: 2. Failed: 1. Skipped: 0.", "because .NET 4.6 tests will pass")
|
||||||
|
@ -61,7 +61,7 @@ namespace Microsoft.DotNet.Cli.Test.Tests
|
||||||
// Call test
|
// Call test
|
||||||
CommandResult result = new DotnetTestCommand()
|
CommandResult result = new DotnetTestCommand()
|
||||||
.WithWorkingDirectory(testProjectDirectory)
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
.ExecuteWithCapturedOutput();
|
.ExecuteWithCapturedOutput(TestBase.ConsoleLoggerOutputNormal);
|
||||||
|
|
||||||
// Verify
|
// Verify
|
||||||
// for target framework net46
|
// for target framework net46
|
||||||
|
|
|
@ -32,7 +32,7 @@ namespace Microsoft.DotNet.Cli.Test.Tests
|
||||||
// Call test
|
// Call test
|
||||||
CommandResult result = new DotnetTestCommand()
|
CommandResult result = new DotnetTestCommand()
|
||||||
.WithWorkingDirectory(testProjectDirectory)
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
.ExecuteWithCapturedOutput();
|
.ExecuteWithCapturedOutput(TestBase.ConsoleLoggerOutputNormal);
|
||||||
|
|
||||||
// Verify
|
// Verify
|
||||||
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
||||||
|
@ -60,7 +60,7 @@ namespace Microsoft.DotNet.Cli.Test.Tests
|
||||||
// Call test
|
// Call test
|
||||||
CommandResult result = new DotnetTestCommand()
|
CommandResult result = new DotnetTestCommand()
|
||||||
.WithWorkingDirectory(testProjectDirectory)
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
.ExecuteWithCapturedOutput();
|
.ExecuteWithCapturedOutput(TestBase.ConsoleLoggerOutputNormal);
|
||||||
|
|
||||||
// Verify
|
// Verify
|
||||||
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
||||||
|
@ -205,7 +205,7 @@ namespace Microsoft.DotNet.Cli.Test.Tests
|
||||||
|
|
||||||
CommandResult result = new DotnetTestCommand()
|
CommandResult result = new DotnetTestCommand()
|
||||||
.WithWorkingDirectory(rootPath)
|
.WithWorkingDirectory(rootPath)
|
||||||
.ExecuteWithCapturedOutput();
|
.ExecuteWithCapturedOutput(TestBase.ConsoleLoggerOutputNormal);
|
||||||
|
|
||||||
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
result.StdOut.Should().Contain("Total tests: 2. Passed: 1. Failed: 1. Skipped: 0.");
|
||||||
result.StdOut.Should().Contain("Passed TestNamespace.VSTestTests.VSTestPassTest");
|
result.StdOut.Should().Contain("Passed TestNamespace.VSTestTests.VSTestPassTest");
|
||||||
|
|
|
@ -34,7 +34,7 @@ namespace Microsoft.DotNet.Cli.VSTest.Tests
|
||||||
.GetDirectory("bin", configuration, "netcoreapp1.0")
|
.GetDirectory("bin", configuration, "netcoreapp1.0")
|
||||||
.GetFile($"{testAppName}.dll");
|
.GetFile($"{testAppName}.dll");
|
||||||
|
|
||||||
var argsForVstest = $"\"{outputDll.FullName}\"";
|
var argsForVstest = $"\"{outputDll.FullName}\" {TestBase.ConsoleLoggerOutputNormal}";
|
||||||
|
|
||||||
// Call vstest
|
// Call vstest
|
||||||
var result = new VSTestCommand().ExecuteWithCapturedOutput(argsForVstest);
|
var result = new VSTestCommand().ExecuteWithCapturedOutput(argsForVstest);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue