Skip to content

Commit

Permalink
Update Run tests workflow: include TestNG results in allure report
Browse files Browse the repository at this point in the history
  • Loading branch information
aqualityAutomation committed Apr 15, 2024
1 parent d9fd8aa commit 80ee98a
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/test-with-allure-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
paths:
- 'aquality-selenium-template/**'
- 'aquality-selenium-template-cucumber/**'
- 'aquality-selenium-template-testng/**'
- 'scripts/**'
push:
branches: [ master ]
Expand All @@ -23,7 +24,8 @@ on:
jobs:
build-and-test:
env:
SUBPROJECT_NAME: aquality-selenium-template-cucumber
CUCUMBER_ALLURE_RESULTS: aquality-selenium-template-cucumber/target/allure-results
TESTNG_ALLURE_RESULTS: aquality-selenium-template-cucumber/target/allure-results
ENVIRONMENT: ${{ github.event.inputs.environment == '' && 'stage' || github.event.inputs.environment }}
GH_PAGES_URL: https://aquality-automation.github.io/aquality-selenium-java-template
concurrency: test-${{ github.event.inputs.environment == '' && 'stage' || github.event.inputs.environment }}
Expand All @@ -47,6 +49,10 @@ jobs:
- name: Test with Maven
id: maven_tests
run: mvn test

- name: Copy TestNG allure result to the Cucumber allure result
if: always()
run: cp -r ${{ env.TESTNG_ALLURE_RESULTS }}. ${{ env.CUCUMBER_ALLURE_RESULTS }}

- name: Get Allure history
uses: actions/checkout@v2
Expand All @@ -61,7 +67,7 @@ jobs:
if: always()
id: allure-report
with:
allure_results: ${{ env.SUBPROJECT_NAME }}/target/allure-results
allure_results: ${{ env.CUCUMBER_ALLURE_RESULTS }}
gh_pages: gh-pages
allure_report: allure-report
allure_history: allure-history
Expand Down

0 comments on commit 80ee98a

Please sign in to comment.