Skip to content

Commit

Permalink
Remove output window logging from integration tests, and see if it ex…
Browse files Browse the repository at this point in the history
…poses a real error (like VSIX not installed I would guess)
  • Loading branch information
davidwengier committed Dec 13, 2023
1 parent f1efe63 commit 85372bc
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,20 @@ internal partial class OutputInProcess

public async Task SetupIntegrationTestLoggerAsync(ITestOutputHelper testOutputHelper, CancellationToken cancellationToken)
{
var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
logger.SetTestLogger(new TestOutputLogger(testOutputHelper));
// var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
// logger.SetTestLogger(new TestOutputLogger(testOutputHelper));
}

public async Task ClearIntegrationTestLoggerAsync(CancellationToken cancellationToken)
{
var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
logger.SetTestLogger(null);
// var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
// logger.SetTestLogger(null);
}

public async Task LogStatusAsync(string message, CancellationToken cancellationToken)
{
var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
logger.LogInformation(message);
// var logger = await TestServices.Shell.GetComponentModelServiceAsync<IOutputWindowLogger>(cancellationToken);
// logger.LogInformation(message);
}

public async Task<bool> HasErrorsAsync(CancellationToken cancellationToken)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ public class LogIntegrationTestAttribute : BeforeAfterTestAttribute
{
public override void Before(MethodInfo methodUnderTest)
{
GetLogger().LogInformation("#### Integration test start: {method}", methodUnderTest.Name);
// GetLogger().LogInformation("#### Integration test start: {method}", methodUnderTest.Name);
}

public override void After(MethodInfo methodUnderTest)
{
GetLogger().LogInformation("#### Integration test end: {method}", methodUnderTest.Name);
// GetLogger().LogInformation("#### Integration test end: {method}", methodUnderTest.Name);
}

private static IOutputWindowLogger GetLogger()
Expand Down

0 comments on commit 85372bc

Please sign in to comment.