Merge pull request #20 from fvaleye/feature/add-dependabot-for-rust #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: python_build | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
defaults: | |
run: | |
working-directory: ./python | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.7 | |
- name: Check Python | |
run: | | |
pip install black isort mypy | |
make check-python | |
- name: Install minimal stable with clippy and rustfmt | |
uses: actions-rs/toolchain@v1 | |
with: | |
profile: default | |
toolchain: stable | |
override: true | |
- name: Check Rust | |
run: make check-rust | |
test: | |
name: Python Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install latest nightly | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
override: true | |
components: rustfmt, clippy | |
- uses: Swatinem/rust-cache@v1 | |
- uses: actions/setup-python@v3 | |
with: | |
python-version: "3.7" | |
- name: Build and install scaphandre | |
run: | | |
pip install virtualenv | |
virtualenv venv | |
source venv/bin/activate | |
make develop | |
- name: Run tests | |
run: | | |
source venv/bin/activate | |
make unit-test | |
- name: Build Sphinx documentation | |
run: | | |
source venv/bin/activate | |
make build-documentation |