Skip to content

Merge pull request #822 from OpenC3/diff #121

Merge pull request #822 from OpenC3/diff

Merge pull request #822 from OpenC3/diff #121

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
# Reference environment variables: https://docs.github.com/en/actions/reference/environment-variables
name: OpenC3 Python Unit Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
OPENC3_CLOUD: local
jobs:
unit-test:
if: ${{ github.actor != 'dependabot[bot]' }}
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
working-directory: openc3/python
- name: Lint with ruff
run: |
ruff --format=github openc3
working-directory: openc3/python
- name: Run unit tests
run: |
python -m unittest
working-directory: openc3/python