| name: Django CI |
| |
| on: |
| push: |
| branches: [ develop ] |
| pull_request: |
| branches: [ develop ] |
| |
| jobs: |
| build: |
| |
| runs-on: ubuntu-latest |
| strategy: |
| max-parallel: 4 |
| matrix: |
| python-version: [3.7, 3.8, 3.9] |
| |
| steps: |
| - uses: actions/checkout@v2 |
| |
| - name: Shutdown Ubuntu MySQL (SUDO) |
| run: sudo service mysql stop # Shutdown the Default MySQL, "sudo" is necessary, please not remove it |
| |
| - name: Start MySQL/Mariadb |
| uses: shogo82148/actions-setup-mysql@v1 |
| with: |
| mysql-version: '5.7' |
| root-password: 'mysql' |
| auto-start: true |
| run: mysql -uroot -pmysql -h127.0.0.1 -e 'CREATE DATABASE fineract_scorecard;' |
| |
| - name: Set up Python ${{ matrix.python-version }} |
| uses: actions/setup-python@v2 |
| with: |
| python-version: ${{ matrix.python-version }} |
| |
| - name: Install Dependencies |
| run: | |
| python -m pip install --upgrade pip |
| pip install -r requirements.txt |
| |
| - name: Run Tests |
| run: | |
| python manage.py test |
| |