Skip to content

Commit e509367

Browse files
committed
"Add support for uploading PHPUnit artifacts in GitHub workflows
Enhanced PHPUnit and RunCommandOnMatrix workflows to support artifact uploading. - Introduced a new `uploadArtifacts` option in both workflows. - Updated PHPUnit.yml to enable uploading test artifacts (e.g., coverage and JUnit XML files) when `uploadArtifacts` is set to true. - Added an optional `uploadArtifacts` input in RunCommandOnMatrix.yml, defaulting to false. - Integrated `actions/upload-artifact` to handle the upload of files matching '*.xml'. This update ensures better test result handling by allowing easy artifact storage and retrieval."
1 parent 8c8cb80 commit e509367

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

.github/workflows/RunCommandOnMatrix.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ on:
2222
command:
2323
type: string
2424
required: true
25+
uploadArtifacts:
26+
type: boolean
27+
required: false
28+
default: false
2529
secrets:
2630
GH_TOKEN:
2731
required: true
@@ -50,4 +54,9 @@ jobs:
5054
- name: Install composer dependencies
5155
run: composer install --no-interaction --no-progress --prefer-dist
5256
- name: ${{ inputs.title }}
53-
run: ${{ inputs.command }}
57+
run: ${{ inputs.command }}
58+
- name: Upload PHPUnit artifacts
59+
if: ${{ inputs.uploadArtifacts }}
60+
uses: actions/upload-artifact@v7
61+
with:
62+
path: '*.xml'

0 commit comments

Comments
 (0)