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

Closes #143 Add report add process to rename and push test files to git #174

Open
wants to merge 12 commits into
base: develop
Choose a base branch
from

Conversation

Khadreal
Copy link
Contributor

@Khadreal Khadreal commented Nov 21, 2024

Description

Created a bash script and a script to move test-results to a central location.

Fixes #143
Organise report after running a test

Type of change

  • Enhancement (non-breaking change which improves an existing functionality).

Detailed scenario

N/A

Technical description

Documentation

You can move the test-results folder for only two test so far(smoke and e2e test). To move the test-results directory after running your test, you need to add a tag parameter without it the test-results won't be move or rename.
Example --
npm run test:smoke --tag= WPR3.17.4_e2e1.0.0
npm run test:e2e --tag= WPR3.17.4_e2e1.0.0

After the test is complete the test-results folder would be rename to WPR3.17.4_e2e1.0.0 and moved to the central localtion(/var/shared/rocket-e2e-reports)

Note -- Without the tag parameter the test-reports won't be move or rename.

Mandatory Checklist

Code validation

  • I validated all the Acceptance Criteria. If possible, provide screenshots or videos.
  • I triggered all changed lines of code at least once without new errors/warnings/notices.
  • I implemented built-in tests to cover the new/changed code.

Code style

  • I wrote a self-explanatory code about what it does.
  • I protected entry points against unexpected inputs.
  • I did not introduce unnecessary complexity.
  • Output messages (errors, notices, logs) are explicit enough for users to understand the issue and are actionnable.

@Khadreal Khadreal marked this pull request as ready for review December 30, 2024 14:50
@Khadreal Khadreal requested a review from a team December 30, 2024 14:50
Copy link
Contributor

@wordpressfan wordpressfan left a comment

Choose a reason for hiding this comment

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

Thanks @Khadreal
do we really need shell file for that task? I was thinking of making the whole code in JS, this will increase simplicity and maintainability.

https://nodejs.org/docs/latest/api/fs.html#fs_fs_rename_oldpath_newpath_callback

What do u think?

@jeawhanlee
Copy link
Contributor

@MathieuLamiot I have a question from the A/C here
Does the 2nd point need to be catered for in this PR? or this would be deleted by the QA after it's stored, because I see that this PR would store reports for every run.

We don't need to store all the reports from all the runs we do, but we would need to keep the representative ones (typically when a next version of the plugin and/or the rocket-E2E is released or tagged)?

@Khadreal
Copy link
Contributor Author

Khadreal commented Jan 3, 2025

No @jeawhanlee, it doesn't store report for every run. It only move the reports and store when the tag parameter is set.

@jeawhanlee
Copy link
Contributor

@Khadreal Correct if I'm wrong, we will move reports & store every time for general test run as well as smoke? no?

@Khadreal
Copy link
Contributor Author

Khadreal commented Jan 3, 2025

@jeawhanlee we would only move report and store for general and smoke test if tag parameter are present if not we wouldn't and the behaviour remains the same before now.

@jeawhanlee
Copy link
Contributor

I had a discussion with @Khadreal, Thanks for the clarification

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.

QA Team - Keeping organized reports of relevant Rocket-E2E runs
3 participants