Skip to content

gccrs-testing-nightly-run #657

gccrs-testing-nightly-run

gccrs-testing-nightly-run #657

Workflow file for this run

name: gccrs-testing-nightly-run
on:
schedule:
- cron: '0 2 * * *' # Run at 2 AM UTC. Does not really matter
workflow_dispatch:
jobs:
run-testsuites:
runs-on: self-hosted
container: philberty/gccrs:latest
strategy:
matrix:
testsuite: [rustc-dejagnu, gccrs-parsing, gccrs-rustc-success, gccrs-rustc-success-no-std, gccrs-rustc-success-no-core, blake3, libcore]
# testsuite: [blake3]
steps:
- name: Fetch dependencies
run: |
# FIXME: Switch to `cargo install ftf` on next release, we need the
# `result-fmt` feature
cargo install --git https://github.com/cohenarthur/ftf
git config --global --add safe.directory "$GITHUB_WORKSPACE"
# we clone new versions of gccrs and rustc, so we must first delete the old ones if they exist
rm -rf local_gccrs || true
rm -rf local_rust || true
git clone https://github.com/rust-gcc/gccrs --depth=1 local_gccrs
git clone https://github.com/rust-lang/rust --branch 1.49.0 local_rust
- name: Generate testsuites (nightly)
run: |
cargo build --release
target/release/testsuite-adaptor --gccrs $(find /usr/local -name 'crab1') --rustc rustc \
--output-dir output-dir-${{ matrix.testsuite }} \
--yaml ${{ matrix.testsuite }}.yaml \
--rust-path local_rust --gccrs-path local_gccrs \
--pass ${{ matrix.testsuite }}
- name: Run testsuite
run: |
echo "{ \"name\": \"${{matrix.testsuite}}\", \"commit\": \"$(cat /GCCRS_BUILD)\", \"date\": \"$(date -I)\", \"results\": " > ${{ matrix.testsuite }}.json
ftf -f ${{ matrix.testsuite }}.yaml -j 1 --result-fmt "{ \"tests\": %t, \"passes\": %p, \"failures\": %f }" | tee log;
tail -n 1 log >> ${{ matrix.testsuite }}.json
echo "}" >> ${{ matrix.testsuite }}.json
- uses: actions/upload-artifact@v3
with:
name: ${{ matrix.testsuite }}.json
path: ${{ matrix.testsuite }}.json