Skip to content

Commit

Permalink
Running unit tests when issuing a PR (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
anw90 authored Aug 22, 2024
1 parent 4436e10 commit d875fc1
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/format_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
pull_request:
push:
branches:
- master
- main
tags:
- r[0-9]+.[0-9]+

Expand Down
26 changes: 26 additions & 0 deletions .github/workflows/unit_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Unit Tests

on:
workflow_dispatch:
pull_request:
push:
branches:
- main
tags:
- r[0-9]+.[0-9]+


jobs:
run-shell-script:
runs-on: self-hosted

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Run unit test
run: |
docker pull $UT_IMAGE
docker run -v $PWD:$PWD -w $PWD --net host --ipc host --shm-size 80G -t --rm --gpus all $UT_IMAGE bash -c 'pip install -r requirements/requirements-test.txt && bash tests/run_ut.sh'
env:
UT_IMAGE: ${{ secrets.UT_IMAGE }}

0 comments on commit d875fc1

Please sign in to comment.