Skip to content

Commit 62b6a22

Browse files
committed
test: finishing functional test setup
1 parent 9f24acc commit 62b6a22

11 files changed

Lines changed: 744 additions & 1233 deletions

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# @devscast/datazen
22

33
# Unreleased
4+
- Unit/schema parity cleanup (Doctrine-reference): fixed SQLite schema-manager parity by removing the SQLite-only `listTableForeignKeys()` database-name bypass and restoring `AbstractSchemaManager` flow, then aligned affected unit tests to Doctrine semantics (`DROP CONSTRAINT` default FK-drop SQL on base platform, unquoted FK column-name expectations in metadata processor output, SQL Server comparator constructor shape with explicit platform). Also validated full local functional matrix (`bun run test:functional:local`) across `sqlite3`, `mysql`, `mariadb`, `postgresql`, and `sqlserver` with all suites passing.
5+
- Functional/Connection parity: replaced two non-PHP `it.skip(...)` placeholders in `src/__tests__/functional/connection.test.ts` with Doctrine-aligned tests using params-based `DriverManager` bootstrap (`connects without an explicit database name`, `determines platform when connecting to a non-existent database`) via `createFunctionalDriverManagerParams()`. Kept only the PHP-native persistent-connection skip.
46
- Functional/Statement parity pass (Datazen-reference): replaced blanket skips in `src/__tests__/functional/statement.test.ts` with runtime-gated behavior aligned to Datazen intent. Added `binds invalid named parameter` (runs only on named-binding drivers), added `fetches long BLOB values` using Node `convertToNodeValue` semantics, and replaced strict numeric assertions with normalized numeric comparisons to match cross-driver equality intent. Also gated `executes with redundant parameters` for drivers/platforms that do not report redundant bindings (named-binding + MySQL-family), and validated this file on `sqlite3`, `mysql`, `mariadb`, `postgresql`, and `sqlserver`.
57
- Schema parity pass (Datazen-reference): aligned `AbstractSchemaManager` list APIs with legacy schema-fetch behavior (`listTableColumns`, `listTableIndexes`, `listTableForeignKeys`) and fixed `introspectTablePrimaryKeyConstraint()` to return `null` when a table is missing. Also aligned FK/PK metadata processors to quoted-name semantics (`PrimaryKeyConstraintColumnMetadataProcessor`, `ForeignKeyConstraintColumnMetadataProcessor`), normalized comparator platform-option null-vs-undefined comparison noise, and updated affected parity tests (`schema-manager`, `foreign-key-constraint-editor`, `abstract-comparator-test-case`, `metadata-providers`, `platform-parity`, `schema-name-introspection`) to match Datazen intent.
68
- Functional/Schema vendor-matrix pass: replaced remaining placeholder `it.skip(...)` files with real, runtime-gated Datazen-reference tests in `src/__tests__/functional/schema/{sqlite-schema-manager,mysql-schema-manager,sql-server-schema-manager,db2-schema-manager,oracle-schema-manager}.test.ts` plus `src/__tests__/functional/schema/mysql/json-collation.test.ts` and `src/__tests__/functional/schema/oracle/comparator.test.ts`.

docs/parity-matrix.md

Lines changed: 0 additions & 77 deletions
This file was deleted.

src/__tests__/functional/_helpers/functional-connection-factory-config.test.ts

Lines changed: 0 additions & 131 deletions
This file was deleted.

src/__tests__/functional/_helpers/functional-test-case.test.ts

Lines changed: 0 additions & 152 deletions
This file was deleted.

0 commit comments

Comments
 (0)