Skip to content

Commit

Permalink
ci: lint + unittests
Browse files Browse the repository at this point in the history
  • Loading branch information
d4l3k committed Oct 27, 2024
1 parent 824a9a3 commit 0c8166a
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Lint

on:
push:
branches:
- main
pull_request:

jobs:
lint:
runs-on: ubuntu-20.04
steps:
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.10"
architecture: x64
- name: Checkout
uses: actions/checkout@v2
- name: Install Dependencies
run: |
set -eux
sudo apt-get install -y protobuf-compiler
pip install .[dev] -v
- name: Run Python Lint
run: |
set -eux
black --check .
- name: Run Rust Lint
run: |
set -eux
cargo fmt --check
39 changes: 39 additions & 0 deletions .github/workflows/unittest.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Unit Tests

on:
push:
branches:
- main
pull_request:

jobs:
unittest:
runs-on: "linux.4xlarge.nvidia.gpu"
steps:
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.10"
architecture: x64
- name: Checkout
uses: actions/checkout@v2
- name: Install Dependencies
run: |
set -eux
sudo apt-get install -y protobuf-compiler
pip install -e .[dev] -v
- name: Run Python Tests
run: |
set -eux
find
pytest -v
- name: Run Rust Lint
run: |
set -eux
cargo test -v

0 comments on commit 0c8166a

Please sign in to comment.