ci:build and test workflow to backend API #1
This file contains hidden or 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: CI/CD MyLibrary Backend build and test | |
| # This workflow will run unit tests with Pytest TODO: IMPLEMENT TEST ON PYTEST | |
| # This workflow is only executed if there is pull request with change in app folder, | |
| on: | |
| pull_request: | |
| branches: | |
| - main # executed on every pull request to main | |
| paths: | |
| - 'app/**' | |
| push: | |
| branches: | |
| - main | |
| release: | |
| types: [published] | |
| jobs: | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Code | |
| uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.10' | |
| - name: install deps | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r ./app/requirements.txt | |
| - name: run Tests | |
| run: echo " TODO implement test on pytest" |