import { describe, expect, test } from 'vitest' import { isSuretypeSchema, isTypeboxSchema } from './resolve-schema-lib.js' import { Type } from 'typebox' import { v } from 'suretype' describe('lib schema resolvers', () => { const typebox = Type.Object({ name: Type.String() }) const suretype = v.object({ name: v.string() }) test('it recognizes TypeBox schema', async () => { expect(isTypeboxSchema(typebox)).toBe(true) expect(isTypeboxSchema(suretype)).toBe(false) }) test('it recognizes Suretype schema', async () => { expect(isSuretypeSchema(suretype)).toBe(true) expect(isSuretypeSchema(typebox)).toBe(false) }) })