BaaRai
53fc8478da
test(db): close the pool after the row cleanups, report cleanup errors
...
A `defer d.Close()` runs when the test function returns, before its
t.Cleanup functions. The cleanups that delete the test's rows then ran on
a closed pool, the error was ignored, and the rows stayed in the database
for the next run. PR #220 fixed three files; this applies the same pattern
to every remaining db test that combines `defer d.Close()` with row
cleanups.
- Close the pool with t.Cleanup, registered before the row cleanups so it
runs last (LIFO).
- Report cleanup errors with t.Errorf through small helpers in
db/cleanup_helpers_test.go. A profile the test already deleted is not an
error.
Test files only. No assertion or production change.
2026-11-14 00:38:00 +01:00
..
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-11 15:47:58 +01:00
2026-10-08 23:14:34 +02:00
2026-11-14 00:38:00 +01:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-14 00:38:00 +01:00
2026-08-28 15:25:20 +08:00
2026-11-10 15:49:41 +01:00
2026-11-10 15:49:41 +01:00
2026-08-24 19:29:14 +08:00
2026-11-14 00:38:00 +01:00
2026-11-13 23:46:42 +01:00
2026-10-08 23:14:34 +02:00
2026-08-31 12:20:31 -04:00
2026-11-13 23:46:42 +01:00
2026-11-13 21:33:27 +01:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-14 00:38:00 +01:00
2026-11-10 23:05:47 +01:00
2026-11-14 00:38:00 +01:00
2026-11-12 20:48:34 +01:00
2026-11-14 00:38:00 +01:00
2026-08-28 15:25:20 +08:00
2026-11-11 00:34:55 +01:00
2026-09-09 11:52:15 -04:00
2026-11-13 22:56:52 +01:00
2026-11-14 00:38:00 +01:00
2026-08-28 14:03:07 +08:00
2026-10-08 23:14:34 +02:00
2026-09-11 08:47:57 +08:00
2026-11-10 17:45:11 +01:00
2026-11-09 12:22:46 +01:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-11 23:43:12 +01:00
2026-10-08 23:14:34 +02:00
2026-11-09 21:47:40 +01:00
2026-11-10 23:05:47 +01:00
2026-09-10 13:03:20 +08:00
2026-11-13 22:56:52 +01:00
2026-11-13 22:56:52 +01:00
2026-11-09 20:21:27 +01:00
2026-10-08 23:14:34 +02:00
2026-11-11 23:43:12 +01:00
2026-08-24 19:29:00 +08:00
2026-11-10 17:45:11 +01:00
2026-08-24 19:29:00 +08:00
2026-10-08 23:14:34 +02:00
2026-11-13 10:14:39 +01:00
2026-11-09 22:35:09 +01:00
2026-11-09 22:17:56 +01:00
2026-11-12 22:35:11 +01:00
2026-09-15 23:51:37 +08:00
2026-10-08 23:14:34 +02:00
2026-11-09 12:22:46 +01:00
2026-10-08 23:14:34 +02:00
2026-11-09 12:22:46 +01:00
2026-11-09 22:35:09 +01:00
2026-09-12 03:00:28 -04:00
2026-10-21 14:25:35 +02:00
2026-10-21 14:25:35 +02:00
2026-08-25 09:40:05 -04:00
2026-10-12 08:53:20 +02:00
2026-08-24 19:28:18 +08:00
2026-11-13 23:46:42 +01:00
2026-10-08 23:14:34 +02:00
2026-07-26 04:27:45 -04:00
2026-10-08 23:14:34 +02:00
2026-11-13 14:42:56 +01:00
2026-10-08 23:14:34 +02:00
2026-11-13 14:42:56 +01:00
2026-11-13 14:42:56 +01:00
2026-11-13 21:33:27 +01:00
2026-11-13 22:56:52 +01:00
2026-10-08 23:14:34 +02:00
2026-11-13 21:33:27 +01:00
2026-09-11 00:41:01 +08:00
2026-10-08 23:14:34 +02:00
2026-10-19 00:33:08 +02:00
2026-08-24 19:30:14 +08:00
2026-08-28 12:56:29 +08:00
2026-11-11 00:34:55 +01:00
2026-11-11 00:34:55 +01:00
2026-08-28 12:56:29 +08:00
2026-11-10 23:05:47 +01:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-12 09:38:52 +01:00
2026-11-14 00:38:00 +01:00
2026-10-08 23:14:34 +02:00
2026-11-14 00:38:00 +01:00
2026-08-24 09:16:44 -04:00
2026-11-14 00:38:00 +01:00
2026-10-08 23:14:34 +02:00
2026-10-08 23:14:34 +02:00
2026-11-13 14:42:56 +01:00
2026-08-24 19:29:00 +08:00
2026-10-08 23:14:34 +02:00
2026-11-14 00:38:00 +01:00
2026-08-25 14:56:15 +08:00
2026-10-19 00:28:27 +02:00
2026-08-24 19:29:00 +08:00
2026-08-09 09:09:59 -04:00
2026-11-12 20:16:23 +01:00
2026-08-24 19:29:00 +08:00
2026-11-14 00:38:00 +01:00
2026-09-19 09:27:03 -04:00
2026-11-14 00:38:00 +01:00
2026-11-12 20:48:34 +01:00
2026-11-13 14:42:56 +01:00
2026-08-25 12:05:26 +08:00
2026-08-28 12:56:29 +08:00
2026-11-13 21:52:27 +01:00
2026-11-13 21:52:27 +01:00
2026-10-08 23:14:34 +02:00