-
Notifications
You must be signed in to change notification settings - Fork 10
46 lines (44 loc) · 1.47 KB
/
linux_tests.yaml
File metadata and controls
46 lines (44 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: linux_test
on:
push:
branches:
- main
pull_request:
# Cancel in-progress CI jobs when a new commit is pushed to a PR.
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
linux_test:
runs-on: ubuntu-latest
steps:
# --- Build the project for release
# Checkout repo to Github Actions runner
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set cores to get stored in /cores
run: |
sudo mkdir /cores
sudo chmod 777 /cores
# Core filenames will be of the form executable.pid.timestamp:
sudo bash -c 'echo "/cores/%e.%p.%t" > /proc/sys/kernel/core_pattern'
- name: test
run: |
# ulimit -c unlimited
set +e
./ci/version_only_change.sh
res="$?"
echo "Script completed with exit code: $res"
if [[ $res -ne 0 ]]; then
set -e
CC=$(which clang) CXX=$(which clang++) ./bazelw test //core/... //platform/... //test/... --config ci --config nomacos --config libunwind --test_output=errors --test_env=RUST_LOG=debug
else
echo "No changes detected in the version-only change script. Skipping tests."
fi
- uses: actions/upload-artifact@v4
if: ${{ failure() }} # Run only if something went wrong
with:
name: cores
path: /cores