Skip to content

Commit

Permalink
try fix postgres CI by running migrate manually
Browse files Browse the repository at this point in the history
  • Loading branch information
bckohan committed Jan 22, 2025
1 parent a6b9fb9 commit 4f77428
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ jobs:
just pin-dependency Django~=${{ matrix.django-version }}
- name: Run Unit Tests
run: |
just run ./manage.py migrate
just test-all
- name: Store coverage files
uses: actions/upload-artifact@v4
Expand Down
8 changes: 3 additions & 5 deletions tests/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,13 @@
# https://docs.djangoproject.com/en/3.2/ref/settings/#databases

rdbms = os.environ.get("RDBMS", "sqlite")

if rdbms == "sqlite":
DATABASES = {
"default": {
"ENGINE": "django.db.backends.sqlite3",
"NAME": "test.db",
"USER": "",
"PASSWORD": "",
"HOST": "",
"PORT": "",
"NAME": BASE_DIR / "db.sqlite3",
"TEST": {"NAME": BASE_DIR / "db.sqlite3"},
}
}
elif rdbms == "postgres":
Expand Down

0 comments on commit 4f77428

Please sign in to comment.