Add if:
condition to search for *.cy*
before attempting to run them
#10
+1
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Proposed changes
Module workflows are failing when the modules have no Cypress tests to run.
See: https://github.com/newfold-labs/wp-module-data/actions/runs/9006556236/job/24744362247?pr=72
I.e.
npm run test:e2e -- --browser chrome --spec "vendor/(newfold-labs/wp-module-data/**/*.cy.js)"
fails.Note: Are those brackets correct? That's how it is in the workflow currently.
Type of Change
Checklist
Further comments
In a plugin, run:
and observe the output is
Run
and observe the output is
I think this should be enough to fix this, although GitHub Actions might not like the expression being evaluated where it is and it might need to be moved to its own step and write to a variable first.
Another solution would be to add
continue-on-error: true