Skip to content

Commit

Permalink
fix: Failing tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
WildEgo committed Mar 3, 2024
1 parent 12ca4f5 commit 0fe1ae1
Show file tree
Hide file tree
Showing 15 changed files with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: errorsResponsesTest.addsAuthErrorResponse, tags: [ErrorsResponsesTest_], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 403: { $ref: '#/components/responses/AuthorizationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { AuthorizationException: { description: 'Authorization error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Error overview.' } }, required: [message] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: errorsResponsesTest.addsErrorsWithCustomRequest, tags: [ErrorsResponsesTest_], parameters: [{ name: foo, in: query, required: true, schema: { type: string } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 422: { $ref: '#/components/responses/ValidationException' }, 403: { $ref: '#/components/responses/AuthorizationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } }, AuthorizationException: { description: 'Authorization error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Error overview.' } }, required: [message] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
'/test/{user}': { get: { operationId: errorsResponsesTest.addsNotFoundErrorResponse, tags: [ErrorsResponsesTest_], parameters: [{ name: user, in: path, required: true, description: 'The user ID', schema: { type: integer } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 404: { $ref: '#/components/responses/ModelNotFoundException' }, 403: { $ref: '#/components/responses/AuthorizationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { ModelNotFoundException: { description: 'Not found', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Error overview.' } }, required: [message] } } } }, AuthorizationException: { description: 'Authorization error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Error overview.' } }, required: [message] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: errorsResponsesTest.addsValidationErrorResponse, tags: [ErrorsResponsesTest_], parameters: [{ name: foo, in: query, required: true, schema: { type: string } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 422: { $ref: '#/components/responses/ValidationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: errorsResponsesTest.phpdocExceptionResponse, tags: [ErrorsResponsesTest_], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 422: { $ref: '#/components/responses/ValidationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: errorsResponsesTest.addsValidationErrorResponseWithFacadeMadeValidators, tags: [ErrorsResponsesTest_], parameters: [{ name: foo, in: query, required: true, schema: { type: string } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 422: { $ref: '#/components/responses/ValidationException' } } } }
tags:
- { name: ErrorsResponsesTest_ }
components:
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: resourceCollectionResponseTest.index, tags: [ResourceCollectionResponseTest_], responses: { 200: { description: '`UserCollection_One`', content: { application/json: { schema: { type: object, properties: { data: { $ref: '#/components/schemas/UserCollection_One' }, something: { type: object, properties: { foo: { type: string, example: bar } }, required: [foo] } }, required: [data, something] } } } } } } }
tags:
- { name: ResourceCollectionResponseTest_ }
components:
schemas: { UserCollection_One: { type: object, properties: { foo: { type: string, example: bar }, users: { type: array, items: { $ref: '#/components/schemas/UserResource' } }, meta: { type: object, properties: { foo: { type: string, example: bar } }, required: [foo] } }, required: [foo, users, meta], title: UserCollection_One }, UserResource: { type: object, properties: { id: { type: integer, example: 1 } }, required: [id], title: UserResource } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: fooTestFour.index, tags: [Foo_TestFour], responses: { 200: { description: 'Simple comment.', content: { application/json: { schema: { type: object, properties: { foo: { type: string, example: bar } }, required: [foo] } } } }, 201: { description: "Advanced comment.\n\nWith more description.", content: { application/json: { schema: { type: object, properties: { foo: { type: string } }, required: [foo] } } } } } } }
tags:
- { name: Foo_TestFour }
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: fooTestThree.index, tags: [Foo_TestThree], responses: { 200: { description: '', content: { application/json: { schema: { anyOf: [{ type: object, properties: { foo: { type: string, example: bar } }, required: [foo] }, { type: object, properties: { foo: { type: string, example: one } }, required: [foo] }] } } } }, 500: { description: '', content: { application/json: { schema: { type: object, properties: { error: { type: object, properties: { msg: { type: string }, code: { type: integer } }, required: [msg, code] } }, required: [error] } } } } } } }
tags:
- { name: Foo_TestThree }
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: fooTestTwo.index, tags: [Foo_TestTwo], responses: { 500: { description: '', content: { application/json: { schema: { type: object, properties: { error: { type: object, properties: { msg: { type: string }, code: { type: integer } }, required: [msg, code] } }, required: [error] } } } } } } }
tags:
- { name: Foo_TestTwo }
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: fooTest.index, tags: [Foo_Test], responses: { 204: { description: 'No content', content: { application/json: { } } } } } }
tags:
- { name: Foo_Test }
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: validationFacadeRulesDocumentingTest.index, tags: [ValidationFacadeRulesDocumenting_Test], parameters: [{ name: content, in: query, required: true, schema: { type: string, enum: [wow] } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } } } } }
tags:
- { name: ValidationFacadeRulesDocumenting_Test }
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: validationRulesDocumentingTest.index, tags: [ValidationRulesDocumenting_Test], parameters: [{ name: content, in: query, required: true, schema: { type: string, enum: [wow] } }], responses: { 200: { description: '`ValidationRulesDocumenting_TestResource`', content: { application/json: { schema: { type: object, properties: { data: { $ref: '#/components/schemas/ValidationRulesDocumenting_TestResource' } }, required: [data] } } } }, 422: { $ref: '#/components/responses/ValidationException' } } } }
tags:
- { name: ValidationRulesDocumenting_Test }
components:
schemas: { ValidationRulesDocumenting_TestResource: { type: object, properties: { id: { type: integer, example: 1 } }, required: [id], title: ValidationRulesDocumenting_TestResource } }
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } } }
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@ security:
- { apiKey: { } }
paths:
/test: { get: { operationId: controllerWithoutSecurity.index, tags: [WithoutSecurity], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } } }, security: [{ }] } }
tags:
- { name: WithoutSecurity }
components:
securitySchemes: { apiKey: { type: apiKey, in: query, name: api_token } }
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,7 @@ servers:
- { url: 'http://localhost/api' }
paths:
/test: { get: { operationId: validationRulesAndFormRequestAtTheSameTimeTest.index, tags: [ValidationRulesAndFormRequestAtTheSameTime_Test], parameters: [{ name: from_form_request, in: query, schema: { type: integer } }, { name: from_validate_call, in: query, required: true, schema: { type: string } }], responses: { 200: { description: '', content: { application/json: { schema: { type: string } } } }, 422: { $ref: '#/components/responses/ValidationException' } } } }
tags:
- { name: ValidationRulesAndFormRequestAtTheSameTime_Test }
components:
responses: { ValidationException: { description: 'Validation error', content: { application/json: { schema: { type: object, properties: { message: { type: string, description: 'Errors overview.' }, errors: { type: object, description: 'A detailed description of each field that failed validation.', additionalProperties: { type: array, items: { type: string } } } }, required: [message, errors] } } } } }

0 comments on commit 0fe1ae1

Please sign in to comment.