Update main.py #67
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
# This workflow will run tests before merging a pull request to the production branch | |
name: Production Test | |
# We want to test when a pull request is: | |
# - opened: pull request is created | |
# - synchronize: at any new modification on the head branch of the PR | |
on: | |
pull_request: | |
types: [opened, synchronize] | |
branches: | |
- main | |
paths-ignore: | |
- "**.ts" # don't rebuild if only infrastructure has changed | |
- "**.md" # don't rebuild if only documentation has changed | |
push: # We also want to test when the PR is merged to subsequently run the deployment workflow | |
branches: | |
- main | |
paths-ignore: | |
- "**.md" # don't rebuild if only documentation has changed | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v3 | |
with: | |
python-version: "3.10" | |
- name: Lint with pylint | |
run: | | |
cd assets/ | |
make lint | |
- name: Test with pytest | |
env: | |
SHA: ${{ github.sha }} | |
run: | | |
cd assets/ | |
make test |