Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve integration test console output #1313

Merged
merged 3 commits into from
Dec 10, 2024
Merged

Conversation

ArinGhazarian
Copy link
Collaborator

@ArinGhazarian ArinGhazarian commented Dec 10, 2024

Description

This PR adds the follows two changes:

  1. By default xUnit only shows the tests outputs after the test was run. This PR adds live outputs to the console during the test run (supported in xUnit Runners v2 2.8.1+), in addition to showing them after the test has completed. This helps a lot with debugging specially debugging the migration script itself.
  2. We used .NET's default Process class for shelling out to run the generated powershell migration script. The problem was the we hadn't redirected the stdout and stderr so we could only see the output of the migrate-repo commands but not the script itself. Redirecting the outputs using the Process class is a bit of a hassle though and not very intuitive so instead we switched to using CliWrap which is a better alternative.

Here is a sample output that we weren't getting before but are getting now with this PR's changes:

image

  • Did you write/update appropriate tests
  • Release notes updated (if appropriate)
  • Appropriate logging output
  • Issue linked
  • Docs updated (or issue created)
  • New package licenses are added to ThirdPartyNotices.txt (if applicable)

Copy link

Unit Test Results

841 tests   841 ✅  20s ⏱️
  1 suites    0 💤
  1 files      0 ❌

Results for commit d00db0d.

Copy link

Code Coverage

Package Line Rate Branch Rate Complexity Health
gei 81% 72% 584
ado2gh 84% 78% 631
Octoshift 87% 77% 1327
bbs2gh 79% 74% 692
Summary 84% (7124 / 8475) 75% (1648 / 2184) 3234

Copy link
Collaborator

@synthead synthead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@ArinGhazarian ArinGhazarian merged commit 8beedac into main Dec 10, 2024
30 checks passed
@ArinGhazarian ArinGhazarian deleted the improve-int-test-outputs branch December 10, 2024 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants