prashant-ramcharan / courgette-jvm

Multiprocess | Parallel Cucumber-JVM | Parallelize your Java Cucumber tests on a feature level or on a scenario level.
MIT License
134 stars 39 forks source link

No Courgette Report is being produced if there are no tags as specified by the user, not in the project repo though. #396

Closed bhala-ki closed 8 months ago

bhala-ki commented 9 months ago

Expected: Expecting the Courgette Report to be produced with no errors & display there are NO tests with the specified tag as the GitHub Actions build is failing as mentioned below in the code section. Actual: No Courgette Report is being produced if there are no tags as specified by the user, not in the project repo though. Run ls target/chrome/courgette-report/ ls target/chrome/courgette-report/ shell: /usr/bin/bash -e ***0*** env: reportPath: /Report JAVA_HOME: /opt/hostedtoolcache/Java_Adopt_jdk/17.0.10-7/x64 CLOUDSDK_METRICS_ENVIRONMENT: github-actions-setup-gcloud GCLOUD_PROJECT: ki-automation-nonprod-a5[2](https://github.com/Ki-Insurance/ki-automation/actions/runs/7992602695/job/21826476336#step:13:2)[3](https://github.com/Ki-Insurance/ki-automation/actions/runs/7992602695/job/21826476336#step:13:3) GOOGLE_APPLICATION_CREDENTIALS: /home/runner/work/ki-automation/ki-automation/cc9897[4](https://github.com/Ki-Insurance/ki-automation/actions/runs/7992602695/job/21826476336#step:13:4)2-79b1-4[5](https://github.com/Ki-Insurance/ki-automation/actions/runs/7992602695/job/21826476336#step:13:5)ba-a329-904c333da[8](https://github.com/Ki-Insurance/ki-automation/actions/runs/7992602695/job/21826476336#step:13:8)e1 GRADLE_BUILD_ACTION_SETUP_COMPLETED: true GRADLE_BUILD_ACTION_CACHE_RESTORED: true ls: cannot access 'target/chrome/courgette-report/': No such file or directory Error: Process completed with exit code 2.

prashant-ramcharan commented 9 months ago

The Courgette report will only be generated if there are actually Cucumber tests that ran.

What is your use case for needing a report when no tests have run?

If your Github action / workflow is non deterministic, would it be better to check the existence of the report file in the Github workflow instead of assuming the report file will always exist?

test -f target/chrome/courgette-report/index.html