Use mpiexec to run unit tests #10
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
--- | |
name: olivine | |
on: | |
issue_comment: | |
types: [ created ] | |
jobs: | |
job_one: | |
runs-on: self-hosted | |
steps: | |
- name: Verify Actor | |
env: | |
ACTOR_TOKEN: ${{ secrets.TOKENIZER }}${{ github.actor }}${{ secrets.TOKENIZER }} | |
ACTOR_ALLOW: ${{ secrets.ACTORLIST }} | |
if: contains( env.ACTOR_ALLOW, env.ACTOR_TOKEN ) | |
id: check | |
run: | | |
echo "triggered=true" >> $GITHUB_OUTPUT | |
- name: grab main project | |
uses: actions/checkout@v4 | |
- name: GitHub API Request | |
if: steps.check.outputs.triggered == 'true' | |
id: request | |
uses: octokit/[email protected] | |
with: | |
route: ${{github.event.issue.pull_request.url}} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Create PR status | |
if: steps.check.outputs.triggered == 'true' | |
uses: geekdude/[email protected] | |
with: | |
authToken: ${{ secrets.GITHUB_TOKEN }} | |
context: "olivine self-hosted" | |
state: "pending" | |
sha: ${{fromJson(steps.request.outputs.data).head.sha}} | |
target_url: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}} | |
- name: Get PR information | |
if: steps.check.outputs.triggered == 'true' | |
id: pr_data | |
run: | | |
echo "branch=${{ fromJson(steps.request.outputs.data).head.ref }}" >> $GITHUB_OUTPUT | |
echo "repo_name=${{ fromJson(steps.request.outputs.data).head.repo.full_name }}" >> $GITHUB_OUTPUT | |
echo "repo_clone_url=${{ fromJson(steps.request.outputs.data).head.repo.clone_url }}" >> $GITHUB_OUTPUT | |
echo "repo_ssh_url=${{ fromJson(steps.request.outputs.data).head.repo.ssh_url }}" >> $GITHUB_OUTPUT | |
- name: Checkout PR branch | |
if: steps.check.outputs.triggered == 'true' | |
uses: actions/checkout@v4 | |
with: | |
token: ${{secrets.GITHUB_TOKEN}} | |
repository: ${{fromJson(steps.request.outputs.data).head.repo.full_name}} | |
ref: ${{steps.pr_data.outputs.branch}} | |
- name: CI Debug | |
if: steps.check.outputs.triggered == 'true' | |
run: | | |
env -0 | while IFS='' read -d '' line ; do printf '%s\t: %s\n' "${line%%=*}" "${line#*=}" | expand -t 30 | sed ':a;N;$!ba;s/\n/ /g'; done | LC_COLLATE=C sort -b > ./env_out.txt | |
- name: Build KORC CPU | |
if: steps.check.outputs.triggered == 'true' | |
run: | | |
./build.sh | |
- name: CTEST | |
if: steps.check.outputs.triggered == 'true' | |
run: | | |
cd ./build && ctest --output-on-failure | |
- name: Report PR status | |
if: always() && steps.check.outputs.triggered == 'true' | |
uses: geekdude/[email protected] | |
with: | |
authToken: ${{ secrets.GITHUB_TOKEN }} | |
context: "olivine self-hosted" | |
state: ${{job.status}} | |
sha: ${{fromJson(steps.request.outputs.data).head.sha}} | |
target_url: https://github.com/${{github.repository}}/actions/runs/${{github.run_id}} | |