@devries-cameron20 / composio Mirror · read-only
Fork 0

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

Mirrored from https://github.com/Camo67/composio.git

Synced Nov 21, 06:00 UTC

next
ts 21 lines 810 Bytes
Raw
1 import { describe, expect, it } from 'vitest';
2 import * as z4 from 'zod/v4';
3 import { version } from 'zod/v4/core';
4
5 import { ZOD_V4_FLOOR, meetsZodV4Floor } from '../../src/backend/zod-v4-floor';
6
7 describe('v4 registry', () => {
8 it('shares the global registry through globalThis', () => {
9 expect((globalThis as { __zod_globalRegistry?: unknown }).__zod_globalRegistry).toBe(
10 z4.globalRegistry
11 );
12 });
13
14 it('runs on a copy that meets the floor', () => {
15 expect(meetsZodV4Floor(version)).toBe(true);
16 expect(meetsZodV4Floor(ZOD_V4_FLOOR)).toBe(true);
17 expect(meetsZodV4Floor({ major: 4, minor: 1, patch: 12 })).toBe(false);
18 expect(meetsZodV4Floor({ major: 4, minor: 0, patch: 0 })).toBe(false);
19 expect(meetsZodV4Floor({ major: 5, minor: 0, patch: 0 })).toBe(true);
20 });
21 });