Chore: make the backend test suite pass on PostgreSQL

Remove SQLite-only assumptions from the tests: hard-coded primary keys,
NULL ordering, the database vendor, and the CPU-dependent default process
count. Keep the test connection open inside the test transaction, since
close_old_connections() and connections.close_all() really close it on
PostgreSQL.
This commit is contained in:
stumpylog committed 2026-10-30 12:55:37 -07:00
1 parent 80a1827fa0
commit 5be95f8fcc
13 files changed
+121 -79

No files matched your search

@@ -19,6 +19,10 @@ class TestFuzzyMatchCommand(TestCase):
call_command(
"document_fuzzy_match",
"--no-progress-bar",
# The default scales with the CPU count and forks, which closes
# the test's database connection on PostgreSQL
"--processes",
"1",
*args,
stdout=stdout,
stderr=stderr,