-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* test: Ignore generated XML output * run_tests: Build RVFI emulators too Can't run tests with them though as they're built for direct instruction injection (RVFI-DII) via an instruction stream over a network socket, not fetching instructions from memory, so this remains just a build test. * run_tests/run_fp_tests: Print summary and give meaningful exit code * run_tests/run_fp_tests: Include tests and failures in top-level XML entity * run_tests/run_fp_tests: Use failure not error for XML output The former is the standard tag for normal test failures, the latter is for catastrophic things like test harness errors. * Run ISA tests in CI
- Loading branch information
Showing
5 changed files
with
130 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: Publish test results | ||
|
||
on: | ||
workflow_run: | ||
workflows: ["CI"] | ||
types: | ||
- completed | ||
|
||
jobs: | ||
publish-test-results: | ||
runs-on: ubuntu-latest | ||
if: github.event.workflow_run.conclusion != 'skipped' | ||
steps: | ||
- name: Download artifacts | ||
uses: actions/github-script@v3.1.0 | ||
with: | ||
script: | | ||
var fs = require('fs'); | ||
var artifacts = await github.actions.listWorkflowRunArtifacts({ | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
run_id: ${{github.event.workflow_run.id }}, | ||
}); | ||
var matchArtifacts = artifacts.data.artifacts.filter((artifact) => { | ||
return artifact.name == 'tests.xml' || artifact.name == 'event.json' | ||
}); | ||
var count = matchArtifacts.length; | ||
for (var i = 0; i < count; i++) { | ||
var matchArtifact = matchArtifacts[i]; | ||
var download = await github.actions.downloadArtifact({ | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
artifact_id: matchArtifact.id, | ||
archive_format: 'zip', | ||
}); | ||
var name = matchArtifact.name; | ||
var dest = name + '.zip' | ||
fs.writeFileSync('${{github.workspace}}/' + dest, Buffer.from(download.data)); | ||
console.log("Downloaded", name, "as", dest); | ||
} | ||
- name: Extract test results | ||
run: unzip tests.xml.zip | ||
- name: Extract event payload | ||
run: unzip event.json.zip | ||
- name: Publish test results | ||
uses: EnricoMi/publish-unit-test-result-action@v1 | ||
with: | ||
commit: ${{ github.event.workflow_run.head_sha }} | ||
event_file: event.json | ||
event_name: ${{ github.event.workflow_run.event }} | ||
files: tests.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/tests.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters