You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
**Purpose**: Confirm the upstream prerequisite PR has landed before
@@ -73,8 +157,8 @@ files.
73
157
**Purpose**: Create the `Profile` / `profiles` test fixture so
74
158
integration tests have a database table and DAB entity to bind to.
75
159
76
-
-[] T002 Add the `profiles` table and the 5 seed rows defined in [data-model.md](./data-model.md) §Table Definition to [src/Service.Tests/DatabaseSchema-MsSql.sql](../../src/Service.Tests/DatabaseSchema-MsSql.sql). Format per copilot-instructions.md MSSQL rules (poorsql, 4-space indent, trailing commas). **MUST NOT touch**`DatabaseSchema-PostgreSql.sql`, `DatabaseSchema-MySql.sql`, `DatabaseSchema-DwSql.sql`, or any CosmosDB schema file (FR-012, Principle I).
77
-
-[] T003 Add the `Profile` entity entry to [src/Service.Tests/dab-config.MsSql.json](../../src/Service.Tests/dab-config.MsSql.json) (source object `dbo.profiles`, anonymous read role for tests as per existing fixture patterns), per [data-model.md](./data-model.md) §DAB Entity. Run `dab validate` against the updated config (no [schemas/dab.draft.schema.json](../../schemas/dab.draft.schema.json) change expected per FR-014 / R11).
160
+
-[x] T002 Add the `profiles` table and the 5 seed rows defined in [data-model.md](./data-model.md) §Table Definition to [src/Service.Tests/DatabaseSchema-MsSql.sql](../../src/Service.Tests/DatabaseSchema-MsSql.sql). Format per copilot-instructions.md MSSQL rules (poorsql, 4-space indent, trailing commas). **MUST NOT touch**`DatabaseSchema-PostgreSql.sql`, `DatabaseSchema-MySql.sql`, `DatabaseSchema-DwSql.sql`, or any CosmosDB schema file (FR-012, Principle I).
161
+
-[x] T003 Add the `Profile` entity entry to [src/Service.Tests/dab-config.MsSql.json](../../src/Service.Tests/dab-config.MsSql.json) (source object `dbo.profiles`, anonymous read role for tests as per existing fixture patterns), per [data-model.md](./data-model.md) §DAB Entity. Run `dab validate` against the updated config (no [schemas/dab.draft.schema.json](../../schemas/dab.draft.schema.json) change expected per FR-014 / R11).
78
162
79
163
**Checkpoint**: Test fixture exists; integration tests added in Phase 5 will resolve their entity references. No production behavior change yet.
80
164
@@ -86,8 +170,8 @@ integration tests have a database table and DAB entity to bind to.
86
170
(R1, R2). Single-line dictionary edit; once landed, JSON columns flow
87
171
through every read / write path that already supports `string`.
88
172
89
-
-[] T004 Add `[SqlDbType.Json] = typeof(string)` to `TypeHelper._sqlDbTypeToType` in [src/Core/Services/TypeHelper.cs](../../src/Core/Services/TypeHelper.cs) (R1). Position the entry adjacent to the existing `NVarChar` / `Text` entries to keep the dictionary readable.
90
-
-[] T005 [P] Unit test: extend the `TypeHelper` test suite (under [src/Service.Tests](../../src/Service.Tests)) to assert `GetSystemTypeFromSqlDbType("json")` returns `typeof(string)` and that `GetJsonDataTypeFromSystemType(typeof(string))` continues to return `JsonDataType.String` (regression check for R2).
173
+
-[x] T004 Add `[SqlDbType.Json] = typeof(string)` to `TypeHelper._sqlDbTypeToType` in [src/Core/Services/TypeHelper.cs](../../src/Core/Services/TypeHelper.cs) (R1). Position the entry adjacent to the existing `NVarChar` / `Text` entries to keep the dictionary readable.
174
+
-[x] T005 [P] Unit test: extend the `TypeHelper` test suite (under [src/Service.Tests](../../src/Service.Tests)) to assert `GetSystemTypeFromSqlDbType("json")` returns `typeof(string)` and that `GetJsonDataTypeFromSystemType(typeof(string))` continues to return `JsonDataType.String` (regression check for R2).
91
175
92
176
**Checkpoint**: Once T004 is merged, `MsSqlMetadataProvider.SqlToCLRType` resolves JSON columns; `OpenApiDocumentor` and `SchemaConverter` emit `string` / `String` automatically. Phase 5 US1 integration tests transition from red to green.
93
177
@@ -101,8 +185,8 @@ SQL errors surface as `400` instead of `500`. Covers BOTH malformed
101
185
JSON on write AND filter operators SQL Server cannot evaluate
102
186
against a JSON column (FR-007; R4 as elevated 2026-06-09).
103
187
104
-
-[] T006 Extend `MsSqlDbExceptionParser.BadRequestExceptionCodes` in [src/Core/Resolvers/MsSqlDbExceptionParser.cs](../../src/Core/Resolvers/MsSqlDbExceptionParser.cs) to include the SQL Server JSON-validation error numbers (R4 lists 13608–13614 as the starting set). PRUNE the speculative set to the actually-triggered numbers using T013 / T014 / T017 / T018 during implementation. Verify that the response body includes the SQL Server error number (R4 notes the existing error envelope serializer may need a small adjustment — verify and amend in this same task or call out a follow-up).
105
-
-[] T007 [P] Unit test: add a `MsSqlDbExceptionParserTests` case (under [src/Service.Tests](../../src/Service.Tests)) asserting that a `SqlException` carrying each of the appended error numbers maps to `HttpStatusCode.BadRequest` via `GetHttpStatusCodeForException`, while a still-unknown number maps to its prior status (regression). Uses the existing `MakeSqlException`-style helper if present, else mocks `SqlException` via reflection per existing test patterns.
188
+
-[x] T006 Extend `MsSqlDbExceptionParser.BadRequestExceptionCodes` in [src/Core/Resolvers/MsSqlDbExceptionParser.cs](../../src/Core/Resolvers/MsSqlDbExceptionParser.cs) to include the SQL Server JSON-validation error numbers (R4 lists 13608–13614 as the starting set). PRUNE the speculative set to the actually-triggered numbers using T013 / T014 / T017 / T018 during implementation. Verify that the response body includes the SQL Server error number (R4 notes the existing error envelope serializer may need a small adjustment — verify and amend in this same task or call out a follow-up).
189
+
-[x] T007 [P] Unit test: add a `MsSqlDbExceptionParserTests` case (under [src/Service.Tests](../../src/Service.Tests)) asserting that a `SqlException` carrying each of the appended error numbers maps to `HttpStatusCode.BadRequest` via `GetHttpStatusCodeForException`, while a still-unknown number maps to its prior status (regression). Uses the existing `MakeSqlException`-style helper if present, else mocks `SqlException` via reflection per existing test patterns.
106
190
107
191
**Checkpoint**: Once T006 lands, every SQL Server JSON error surfaces as 400 / `BAD_REQUEST` with the SQL error number in the response body. T013 / T014 (malformed write) and T017 / T018 (unsupported filter operator) go green.
0 commit comments