add tests for $and and $description #59
Annotations
5 errors and 1 warning
Tests:
applications/__tests__/e2e-bundle.test.js#L113
Error: Snapshot `bundle > openapi with $and and $description 1` mismatched
- Expected
+ Received
- "openapi: 3.1.0
- info:
- title: Test
- version: 1.0.0
- paths:
- /test:
- get:
- responses:
- '200':
- description: Test $and with $description.
- content:
- application/json:
- x-type:
- $and:
- - az:
- bukh: vidh
- $descriptions:
- bukh: Description of az.bukh
- - az:
- glagol: dobro
- $descriptions:
- glagol: Description of az.glagol
- examples:
- Correct:
- value:
- az:
- bukh: vidh
- glagol: dobro
- Incorrect:
- value:
- az:
- glagol: vidh
- not-expected: fail
- schema:
- type: object
- properties:
- az:
- type: object
- properties:
- bukh:
- description: Description of az.bukh
- type: string
- enum:
- - vidh
- glagol:
- description: Description of az.glagol
- type: string
- enum:
- - dobro
- required:
- - bukh
- - glagol
- additionalProperties: false
- required:
- - az
- additionalProperties: false
- components: {}
- "
+ undefined
❯ applications/__tests__/e2e-bundle.test.js:113:20
|
Tests:
applications/__tests__/e2e-lint.test.js#L82
Error: Snapshot `lint > openapi with $and and $description 1` mismatched
- Expected
+ Received
- "validating applications/resources/openapi-and-with-descriptions.yaml...
- [1] applications/resources/openapi-and-with-descriptions.yaml:35:23 at #/paths/~1test/get/responses/200/content/application~1json/examples/Incorrect/value/az
-
- Example value must conform to the schema: `az` property must have required property 'bukh'.
-
- 33 | az:
- 34 | # missing bukh
- 35 | glagol: vidh
- | ^^^^^^^^^^^^
- 36 | not-expected: fail
- | ^^^^^^^^^^^^^^^^^^
- 37 |
-
- referenced from applications/resources/openapi-and-with-descriptions.yaml:13:15 at #/paths/~1test/get/responses/200/content/application~1json
-
- Error was generated by the no-invalid-media-type-examples rule.
-
-
- [2] applications/resources/openapi-and-with-descriptions.yaml:36:23 at #/paths/~1test/get/responses/200/content/application~1json/examples/Incorrect/value/az/not-expected
-
- Example value must conform to the schema: `az` property must NOT have additional properties `not-expected`.
-
- 34 | # missing bukh
- 35 | glagol: vidh
- 36 | not-expected: fail
- | ^^^^^^^^^^^^
- 37 |
-
- referenced from applications/resources/openapi-and-with-descriptions.yaml:13:15 at #/paths/~1test/get/responses/200/content/application~1json
-
- Error was generated by the no-invalid-media-type-examples rule.
-
+ "
+ applications/resources/openapi-and-with-descriptions.yaml does not exist or is invalid.
- [3] applications/resources/openapi-and-with-descriptions.yaml:35:31 at #/paths/~1test/get/responses/200/content/application~1json/examples/Incorrect/value/az/glagol
-
- Example value must conform to the schema: `glagol` property must be equal to one of the allowed values "dobro".
-
- Did you mean: dobro ?
-
- 33 | az:
- 34 | # missing bukh
- 35 | glagol: vidh
- | ^^^^
- 36 | not-expected: fail
- 37 |
-
- referenced from applications/resources/openapi-and-with-descriptions.yaml:13:15 at #/paths/~1test/get/responses/200/content/application~1json
-
- Error was generated by the no-invalid-media-type-examples rule.
-
-
- applications/resources/openapi-and-with-descriptions.yaml: validated in <test>ms
-
- ❌ Validation failed with 3 errors.
- run `redocly lint --generate-ignore-file` to add all problems to the ignore file.
+ Please provide a valid path.
"
❯ applications/__tests__/e2e-lint.test.js:82:30
|
Tests
Process completed with exit code 1.
|
Coverage Report
Failed to parse the json-summary at path "/home/runner/work/json-types/json-types/coverage/coverage-summary.json."
Make sure to run vitest before this action and to include the "json-summary" reporter.
Original Error:
Error: ENOENT: no such file or directory, open '/home/runner/work/json-types/json-types/coverage/coverage-summary.json'
at async open (node:internal/fs/promises:636:25)
at async readFile (node:internal/fs/promises:1246:14)
at async Mr (/home/runner/work/_actions/davelosert/vitest-coverage-report-action/v1/dist/index.js:42:177)
at async $r (/home/runner/work/_actions/davelosert/vitest-coverage-report-action/v1/dist/index.js:42:258)
at async dn (/home/runner/work/_actions/davelosert/vitest-coverage-report-action/v1/dist/index.js:83:287)
|
Coverage Report
Error: ENOENT: no such file or directory, open '/home/runner/work/json-types/json-types/coverage/coverage-summary.json'
|
The following actions use a deprecated Node.js version and will be forced to run on node20: actions/checkout@v3, actions/setup-node@v3, davelosert/vitest-coverage-report-action@v1. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
|
Loading