Skip to content

Commit

Permalink
πŸ‘ add migration
Browse files Browse the repository at this point in the history
  • Loading branch information
shun198 committed Jun 9, 2024
1 parent 0ee88be commit cadcd81
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/test-without-model.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
run: |
git fetch origin ${{ github.base_ref }}
MODEL_CHANGED=false
if git diff --name-only origin/$BASE_BRANCH ${{ github.sha }} | grep -q "^${{ env.WORKING_DIRECTORY }}/application/models/"; then
if git diff --name-only origin/$BASE_BRANCH ${{ github.sha }} | grep -q "^${{ env.WORKING_DIRECTORY }}/models/"; then
MODEL_CHANGED=true
fi
echo "MODEL_CHANGED=$MODEL_CHANGED" >> $GITHUB_ENV
Expand All @@ -54,10 +54,10 @@ jobs:
uses: ./.github/actions/set-up-poetry
with:
working-directory: ${{ env.WORKING_DIRECTORY }}
# - name: Run migration
# run: |
# poetry run python manage.py makemigrations
# poetry run python manage.py migrate
- name: Run migration
run: |
poetry run python manage.py makemigrations
poetry run python manage.py migrate
- name: Run Pytest Without Model
if: env.MODEL_CHANGED == 'true'
run: |
Expand Down

0 comments on commit cadcd81

Please sign in to comment.