persona-community-5/.pnpm-store/v3/files/b3/f3bc905c89e9ce44d143375d365b5f6bfac0b02b9ffb7ceb8d772a43043cad6c8791f9bbedb8d16a04c970928a374c45d8f7936a1466695e9545385b8a7711
rdev-worker a1d0d1bf1c
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
build: /implement-feature community-ui --requirements 'Build the React commu...
2026-02-24 08:22:30 +00:00

42 lines
1.1 KiB
Plaintext

import { outdent } from 'outdent';
import { validateDoc } from './utils';
it('should not fail on valid callbacks object', async () => {
const source = outdent`
openapi: 3.0.2
info:
title: Test
version: '1.0'
servers:
- url: http://google.com
paths:
'/ping':
summary: test
get:
callbacks:
test:
'http://notificationServer.com?transactionId={$request.body#/id}&email={$request.body#/email}':
post:
requestBody:
description: Callback payload
content:
'application/json':
schema:
$ref: '#/components/schemas/SomePayload'
responses:
'200':
description: webhook successfully processed and no retries will be performed
responses:
'200':
description: example description
`;
expect(
await validateDoc(source, {
spec: 'error',
})
).toMatchInlineSnapshot(`[]`);
});