fix(schema): generate full JSON schema with Zod v4

This commit is contained in:
YeonGyu-Kim
2026-02-13 11:08:15 +09:00
parent 260acdc140
commit d6754c96bc
4 changed files with 3331 additions and 15 deletions
+18
View File
@@ -0,0 +1,18 @@
import { describe, expect, test } from "bun:test"
import { createOhMyOpenCodeJsonSchema } from "./build-schema-document"
describe("build-schema-document", () => {
test("generates schema with skills property", () => {
// given
const expectedDraft = "http://json-schema.org/draft-07/schema#"
// when
const schema = createOhMyOpenCodeJsonSchema()
// then
expect(schema.$schema).toBe(expectedDraft)
expect(schema.title).toBe("Oh My OpenCode Configuration")
expect(schema.properties).toBeDefined()
expect(schema.properties.skills).toBeDefined()
})
})