Skip to content

Commit d2836f4

Browse files
committed
fix: renamed testcase REAL_WORLD_POLICY_EVALUATION_ROUTE for clarity
1 parent 9396a0e commit d2836f4

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

packages/openapi-generator/test/openapi/union.test.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -361,11 +361,9 @@ export const route = h.httpRoute({
361361
path: '/internal/api/policy/v1/{applicationName}/touchpoints/{touchpoint}/rules/evaluation',
362362
method: 'POST',
363363
request: t.union([
364-
// First schema has NO path parameters - this was causing the bug
365364
h.httpRequest({
366365
body: { emptyRequest: t.boolean }
367366
}),
368-
// Second schema HAS path parameters - these should be preserved
369367
h.httpRequest({
370368
params: {
371369
applicationName: t.string,
@@ -539,7 +537,7 @@ testCase(
539537
},
540538
);
541539

542-
const REAL_WORLD_POLICY_EVALUATION_ROUTE = `
540+
const ROUTE_WITH_FULLY_DEFINED_PARAMS = `
543541
import * as t from 'io-ts';
544542
import * as h from '@api-ts/io-ts-http';
545543
@@ -597,8 +595,8 @@ export const route = h.httpRoute({
597595
`;
598596

599597
testCase(
600-
'real-world policy evaluation route with union request bodies',
601-
REAL_WORLD_POLICY_EVALUATION_ROUTE,
598+
'union request with consistently defined path parameters',
599+
ROUTE_WITH_FULLY_DEFINED_PARAMS,
602600
{
603601
info: {
604602
title: 'Test',

0 commit comments

Comments
 (0)