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

Fix junit and jest-stare output in wrong folder #167

Merged
merged 1 commit into from
Oct 14, 2024

Conversation

t1m0thyj
Copy link
Member

What It Does

Typically the __tests__/__results__ directory is structured like the following for unit test results:

__tests__
 |- __results__
     |- unit
        |- coverage
        |- jest-stare
        |- junit.xml

This PR fixes jest-stare folder being duplicated and junit.xml file being at wrong level:

__tests__
 |- __results__
     |- jest-stare
     |- unit
        |- coverage
        |- jest-stare
     |- junit.xml

How to Test

Review Checklist
I certify that I have:

Additional Comments

Once this PR and related ones for other plug-ins are merged, the Zowe CLI Coverage workflow should start passing again 😋

Signed-off-by: Timothy Johnson <timothy.johnson@broadcom.com>
Copy link

sonarcloud bot commented Oct 10, 2024

Copy link

codecov bot commented Oct 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.77%. Comparing base (6b78c85) to head (4aed442).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #167   +/-   ##
=======================================
  Coverage   74.77%   74.77%           
=======================================
  Files          24       24           
  Lines         337      337           
  Branches       43       44    +1     
=======================================
  Hits          252      252           
  Misses         85       85           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

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

Thanks for fixing! 🙏

I didn't realize that the results where not passed to other reporters as expected

# Before
**  jest-stare --testResultsProcessor: wrote output report to __tests__/__results__/unit/jest-stare/index.html  **

# After
**  jest-stare --testResultsProcessor: wrote output report to __tests__/__results__/unit/jest-stare/index.html  **
**  jest-stare passed results to additional processor "jest-junit"      **
**  jest-stare passed results to additional processor "jest-html-reporter"      **

@t1m0thyj
Copy link
Member Author

Thanks for fixing! 🙏

I didn't realize that the results where not passed to other reporters as expected

No problem 😋 I should probably mention because it confused me at first, that moving the jest-stare config out of the reporters section is what fixed the folder duplication. Defining it there may not behave as intended per its readme:

Note: testResultsProcessor will not use config options specified in the way above

Copy link
Member

@traeok traeok left a comment

Choose a reason for hiding this comment

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

LGTM, thanks Timothy

@t1m0thyj t1m0thyj merged commit 00b850c into master Oct 14, 2024
20 checks passed
@t1m0thyj t1m0thyj deleted the fix/jest-stare-config branch October 14, 2024 13:36
@t1m0thyj t1m0thyj added the release-current Indicates that there is no new functionality being delivered label Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-changelog release-current Indicates that there is no new functionality being delivered
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

3 participants