Skip to content

Commit

Permalink
Explicitly set the test database name
Browse files Browse the repository at this point in the history
Currently we are relying on Django’s internal test setup to add a `test_` prefix
to the default database name. This works fine most of the time but it’s better
to be explicit.
  • Loading branch information
samdoran committed Feb 14, 2024
1 parent 75a9c3c commit c3e2eb9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions koku/koku/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,9 @@ def config():
"HOST": CONFIGURATOR.get_database_host(),
"PORT": CONFIGURATOR.get_database_port(),
"OPTIONS": {"application_name": ENVIRONMENT.get_value("APPLICATION_NAME", default="koku")},
"TEST": {
"NAME": f"test_{name}",
},
}

database_cert = CONFIGURATOR.get_database_ca()
Expand Down

0 comments on commit c3e2eb9

Please sign in to comment.