fix(coding): tighten Pi Data Service schemas
This commit is contained in:
@@ -243,6 +243,15 @@ describe('Makelore Pi extension bundle', () => {
|
||||
expect(Object.keys(tool?.parameters?.properties ?? {})).not.toEqual(
|
||||
expect.arrayContaining(['owner', 'project', 'path', 'token', 'endpoint', 'url', 'handle']),
|
||||
);
|
||||
const properties = tool?.parameters?.properties as Record<string, Record<string, unknown>>;
|
||||
if (name === 'data_service_get_document'
|
||||
|| name === 'data_service_put_document'
|
||||
|| name === 'data_service_delete_document') {
|
||||
expect(properties.document_id?.not).toEqual({ enum: ['.', '..'] });
|
||||
}
|
||||
if (name === 'data_service_put_document' || name === 'data_service_delete_document') {
|
||||
expect(properties.if_revision?.maximum).toBe(Number.MAX_SAFE_INTEGER);
|
||||
}
|
||||
}
|
||||
|
||||
const updates: unknown[] = [];
|
||||
|
||||
Reference in New Issue
Block a user