@zerotal/testing 1.15.1 → 1.15.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -8,6 +8,15 @@ follows the Zerotal monorepo's unified versioning.
8
8
 
9
9
  ## [Unreleased]
10
10
 
11
+ ## [1.15.2] — 2026-10-23
12
+
13
+ ### Fixed
14
+
15
+ - **`assertDatabaseHas`, `assertDatabaseMissing` and `assertDatabaseCount` run on Bun
16
+ 1.4.4.** They counted rows through a hand-built template object whose `raw` was
17
+ enumerable, which Bun 1.4.4 refuses. They use the ORM's `_templateStrings()` now; see
18
+ `@zerotal/orm`.
19
+
11
20
  ## [1.15.1] — 2026-09-13
12
21
 
13
22
  ### Fixed
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zerotal/testing",
3
- "version": "1.15.1",
3
+ "version": "1.15.2",
4
4
  "license": "MIT",
5
5
  "maturity": "stable",
6
6
  "private": false,
@@ -32,14 +32,14 @@
32
32
  "typecheck": "tsc --noEmit"
33
33
  },
34
34
  "dependencies": {
35
- "@zerotal/core": "1.15.1",
36
- "@zerotal/orm": "1.15.1",
37
- "@zerotal/queue": "1.15.1",
38
- "@zerotal/notifications": "1.15.1"
35
+ "@zerotal/core": "1.15.2",
36
+ "@zerotal/orm": "1.15.2",
37
+ "@zerotal/queue": "1.15.2",
38
+ "@zerotal/notifications": "1.15.2"
39
39
  },
40
40
  "devDependencies": {
41
41
  "typescript": "^5.8.0",
42
- "@zerotal/session": "1.15.1"
42
+ "@zerotal/session": "1.15.2"
43
43
  },
44
44
  "description": "Testing utilities for Zerotal — an in-process test app, HTTP helpers, and database refresh.",
45
45
  "keywords": [
package/src/assertions.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { _getModelConnection } from "@zerotal/orm";
1
+ import { _getModelConnection, _templateStrings } from "@zerotal/orm";
2
2
 
3
3
  async function countRows(table: string, where: Record<string, unknown>): Promise<number> {
4
4
  const conn = _getModelConnection() as unknown as (
@@ -19,7 +19,7 @@ async function countRows(table: string, where: Record<string, unknown>): Promise
19
19
  });
20
20
  parts.push(sql);
21
21
 
22
- const tpl = Object.assign([...parts], { raw: [...parts] }) as unknown as TemplateStringsArray;
22
+ const tpl = _templateStrings(parts);
23
23
  const rows = await conn(tpl, ...vals);
24
24
  return Number(rows[0]?.cnt ?? 0);
25
25
  }