LifeMate — Personal, Family & Learning Companion
test: admit the exact local synthetic CI database for feedback
Quinn White committed
Oct 11, 2026 at 14:50 UTC
b3a62b76bf93697d050b896bc5f99ad6e8fb2f2f
1 file changed
+5
-1
backend/tests/learning_feedback.test.js
+5
-1
@@ -93,7 +93,11 @@ describe('learning feedback authenticated real HTTP and synthetic PostgreSQL', {
93
const location = new URL(process.env.TEST_FIXTURE_DATABASE_URL ?? process.env.DATABASE_URL);
94
assert.ok(['localhost', '127.0.0.1', '[::1]', '::1'].includes(location.hostname),
95
'Feedback tests refuse a nonlocal database');
96
- assert.ok(location.pathname.includes('test') || /^\/lifeguide_roles_source_[a-f0-9]{16}$/.test(location.pathname), 'Feedback tests require an explicit synthetic test database');
96
+ // Keep the local-host gate above. The workflow's existing synthetic database
97
+ // has a protocol/history name; admitting that exact name does not admit arbitrary DBs.
98
+ assert.ok(location.pathname.includes('test') || location.pathname === '/lifemate_ci' ||
99
+ /^\/lifeguide_roles_source_[a-f0-9]{16}$/.test(location.pathname),
100
+ 'Feedback tests require an explicit synthetic test database');
101
pool = new pg.Pool({ connectionString: process.env.TEST_FIXTURE_DATABASE_URL ?? process.env.DATABASE_URL });
102
await start();
103
});