Skip to content

Commit

Permalink
ci: upload test artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
uael committed Oct 16, 2023
1 parent 083da7d commit 5af320e
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
23 changes: 12 additions & 11 deletions .github/workflows/avatar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,17 +58,14 @@ jobs:
- run: black --check avatar/
- run: isort --check avatar
test:
name: Test Bumble vs Bumble(s) [${{ matrix.shard }}]
name: Test Bumble vs Bumble(s) [${{ matrix.shard }}/24]
runs-on: ubuntu-latest
strategy:
matrix:
shard: [
1/24, 2/24, 3/24, 4/24,
5/24, 6/24, 7/24, 8/24,
9/24, 10/24, 11/24, 12/24,
13/24, 14/24, 15/24, 16/24,
17/24, 18/24, 19/24, 20/24,
21/24, 22/24, 23/24, 24/24,
1, 2, 3, 4, 5, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16,
17, 18, 19, 20, 21, 22, 23, 24,
]
steps:
- uses: actions/checkout@v3
Expand All @@ -81,11 +78,15 @@ jobs:
pip install --upgrade pip
pip install rootcanal==1.3.0
pip install .
mkdir -p out
- name: Rootcanal
run: nohup python -m rootcanal > rootcanal.log &
run: nohup python -m rootcanal > out/rootcanal.log &
- name: Test
run: |
avatar --list | grep -Ev '^=' > test-names.txt
timeout 5m avatar --test-beds bumble.bumbles --tests $(split test-names.txt -n l/${{ matrix.shard }})
- name: Rootcanal Logs
run: cat rootcanal.log
timeout 5m avatar --test-beds bumble.bumbles --tests $(split test-names.txt -n l/${{ matrix.shard }}/24)
- uses: actions/upload-artifact@v3
if: success() || failure()
with:
name: artifacts_${{ matrix.shard }}
path: out/
3 changes: 3 additions & 0 deletions avatar/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ def run(self) -> bool:
# Enable Bumble snoop logs.
os.environ.setdefault('BUMBLE_SNOOPER', f'btsnoop:file:{self.logs_dir}/{_BUMBLE_BTSNOOP_FMT}')

# Set Mobly log path.
os.environ.setdefault('ENV_MOBLY_LOGPATH', str(self.logs_dir))

# Execute the suite
ok = True
for config in self.test_run_configs:
Expand Down

0 comments on commit 5af320e

Please sign in to comment.