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

Github action summary added #141

Merged
merged 4 commits into from
May 8, 2023
Merged

Github action summary added #141

merged 4 commits into from
May 8, 2023

Conversation

jayedul
Copy link
Contributor

@jayedul jayedul commented May 2, 2023

Description of the Change

Mochawesome reporter added for Cypress test report
Screenshot 2023-05-02 at 4 27 31 PM

Closes #124

Changelog Entry

Added - Mochawesome reporter added for Cypress test report

Credits

Props @jayedul

Checklist:

  • I agree to follow this project's Code of Conduct.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests pass.

@jayedul jayedul self-assigned this May 2, 2023
@jayedul jayedul marked this pull request as ready for review May 2, 2023 10:37
@jayedul jayedul marked this pull request as draft May 2, 2023 11:40
@peterwilsoncc
Copy link
Contributor

@jayedul I noticed you marked this ready and then reverted to draft. I can see the data being included (my last commit testing it deliberately breaks a few things) but I'm not sure if I should be seeing the screen shot you've provided in the description on the summary tab.

@jayedul
Copy link
Contributor Author

jayedul commented May 8, 2023

Thank you @peterwilsoncc for this commit c4193f1

I was wondering why all the E2E tests were not running after adding GH summary commands. That's why I reverted to draft to check later. As I can see this commit resolved the issue, this PR is ready to review now. And I'll have to use this fix in some other PRs that has this same issue.

I'm not sure if I should be seeing the screen shot you've provided in the description on the summary tab.

You should if you run the following commands in your local system sequentially after running E2E tests.
npx mochawesome-merge ./tests/cypress/reports/*.json -o tests/cypress/reports/mochawesome.json
rm -rf ./tests/cypress/reports/mochawesome-*.json
npx mochawesome-json-to-md -p ./tests/cypress/reports/mochawesome.json -o ./tests/cypress/reports/mochawesome.md
npx mochawesome-report-generator tests/cypress/reports/mochawesome.json -o tests/cypress/reports/

It will generate mochawesome.html file in the directory ./tests/cypress/reports that you can open in any browser.

However for Github actions, I guess nothing else to do apart from checking if the scripts passed successfully. Or maybe @faisal-alvi can suggest something as he has some similar PR merged like this one 10up/simple-local-avatars#174

@jayedul jayedul marked this pull request as ready for review May 8, 2023 09:35
@jeffpaul jeffpaul removed their request for review May 8, 2023 14:33
@jeffpaul jeffpaul added this to the 1.5.0 milestone May 8, 2023
@peterwilsoncc peterwilsoncc force-pushed the update/124 branch 2 times, most recently from f85b28e to 550308b Compare May 8, 2023 23:35
Copy link
Contributor

@peterwilsoncc peterwilsoncc left a comment

Choose a reason for hiding this comment

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

This LGTM, thanks!

I pushed a minor change as noted inline.

I've tested an action run with broken tests, but have since force pushed the relevant commit out of the history to avoid noise.

@@ -53,3 +53,22 @@ jobs:
run: npm run env:start
- name: Test
run: npm run cypress:run
- name: Update summary
if: always()
Copy link
Contributor

Choose a reason for hiding this comment

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

I pushed this in 550308b to ensure the summary is displayed for both test passes and failures.

@peterwilsoncc peterwilsoncc merged commit bade26b into develop May 8, 2023
@peterwilsoncc peterwilsoncc deleted the update/124 branch May 8, 2023 23:43
@dkotter dkotter modified the milestones: 1.5.0, 1.4.3 Jun 16, 2023
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.

Add a GH Actions summary
4 participants