Skip to content

Commit b6159ba

Browse files
author
Indra Prajapati
committed
xml
1 parent 6081c33 commit b6159ba

File tree

1 file changed

+25
-19
lines changed

1 file changed

+25
-19
lines changed

.github/workflows/main.yml

Lines changed: 25 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -34,25 +34,31 @@ jobs:
3434
# uses: mikepenz/action-junit-report@v3
3535
# with:
3636
# report_paths: 'reports/junit-report.xml'
37-
- name: Debug Cucumber JSON Report
38-
run: cat test-results/cucumber-report.json
39-
- name: Add Test Case-wise Summary to GitHub Actions
40-
if: always()
41-
run: |
42-
echo "### 📝 Test Execution Summary" >> $GITHUB_STEP_SUMMARY
43-
echo "| Status | Test Case | Feature |" >> $GITHUB_STEP_SUMMARY
44-
echo "|---------|----------|---------|" >> $GITHUB_STEP_SUMMARY
45-
cat test-results/cucumber-report.json | jq -r '
46-
.[] |
47-
{feature: .name, scenarios: .elements} |
48-
.scenarios[] |
49-
{scenario: .name, status: ([.steps[].result.status] | unique | join(",")), feature: input.feature} |
50-
if .status == "passed" then
51-
"| ✅ Pass | \(.scenario) | \(.feature) |"
52-
elif .status == "failed" then
53-
"| ❌ Fail | \(.scenario) | \(.feature) |"
54-
else empty
55-
end' >> $GITHUB_STEP_SUMMARY
37+
# - name: Debug Cucumber JSON Report
38+
# run: cat test-results/cucumber-report.json
39+
# - name: Add Test Case-wise Summary to GitHub Actions
40+
# if: always()
41+
# run: |
42+
# echo "### 📝 Test Execution Summary" >> $GITHUB_STEP_SUMMARY
43+
# echo "| Status | Test Case | Feature |" >> $GITHUB_STEP_SUMMARY
44+
# echo "|---------|----------|---------|" >> $GITHUB_STEP_SUMMARY
45+
# cat test-results/cucumber-report.json | jq -r '
46+
# .[] |
47+
# {feature: .name, scenarios: .elements} |
48+
# .scenarios[] |
49+
# {scenario: .name, status: ([.steps[].result.status] | unique | join(",")), feature: input.feature} |
50+
# if .status == "passed" then
51+
# "| ✅ Pass | \(.scenario) | \(.feature) |"
52+
# elif .status == "failed" then
53+
# "| ❌ Fail | \(.scenario) | \(.feature) |"
54+
# else empty
55+
# end' >> $GITHUB_STEP_SUMMARY
56+
- name: Publish Test Report
57+
uses: dorny/test-reporter@v1
58+
with:
59+
name: Cucumber Report
60+
path: reports/junit-report.xml
61+
reporter: java-junit
5662
- uses: actions/upload-artifact@v4
5763
if: ${{ !cancelled() }}
5864
with:

0 commit comments

Comments
 (0)