diff --git a/.github/workflows/copilot_deploy.yml b/.github/workflows/copilot_deploy.yml index f9b3315..769f6e5 100644 --- a/.github/workflows/copilot_deploy.yml +++ b/.github/workflows/copilot_deploy.yml @@ -52,7 +52,8 @@ jobs: pre_deploy_tests: uses: communitiesuk/funding-service-design-workflows/.github/workflows/pre-deploy.yml@main with: - postgres_unit_testing: false + postgres_unit_testing: true + db_name: fab_unit_test paketo_build: needs: [ setup ] diff --git a/config/envs/unit_test.py b/config/envs/unit_test.py index 0703936..526846e 100644 --- a/config/envs/unit_test.py +++ b/config/envs/unit_test.py @@ -1,4 +1,5 @@ import logging +from os import getenv from fsd_utils import configclass @@ -11,4 +12,6 @@ class UnitTestConfig(Config): # Logging FSD_LOG_LEVEL = logging.DEBUG - SQLALCHEMY_DATABASE_URI = "postgresql://postgres:password@fab-db:5432/fab_unit_test" # pragma: allowlist secret + SQLALCHEMY_DATABASE_URI = getenv( + "DATABASE_URL", "postgresql://postgres:postgres@127.0.0.1:5432/fab_unit_test" # pragma: allowlist secret + )