Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(cmd-api-server): health-check endpoint crash - no OpenAPI metadata #35

Closed
petermetz opened this issue Dec 21, 2022 · 0 comments · Fixed by #36
Closed

fix(cmd-api-server): health-check endpoint crash - no OpenAPI metadata #35

petermetz opened this issue Dec 21, 2022 · 0 comments · Fixed by #36
Assignees
Labels
bug Something isn't working

Comments

@petermetz
Copy link
Owner

$ yarn tap --ts --timeout=6666 --no-coverage pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.362Z] DEBUG (config-service): Configuration validation OK.
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.363Z] INFO (api-server): Setting tls.DEFAULT_MAX_VERSION to TLSv1.3...
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.364Z] INFO (api-server): wwwRoot: ./node_modules/@dci-lint/cockpit/www/
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.364Z] INFO (api-server): resolvedWwwRoot:
/****/dci-lint/node_modules/@dci-lint/cockpit/www
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.364Z] INFO (api-server): resolvedIndexHtml:
/****/dci-lint/node_modules/@dci-lint/cockpit/www/index.html
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.366Z] INFO (api-server): Cockpit net.AddressInfo { address:
'127.0.0.1', family: 'IPv4', port: 37591 }
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.370Z] INFO (api-server): Starting to install web services...
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.371Z] DEBUG (IgnoreFileParser): Created instance OK
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.371Z] INFO (api-server): DCI Lint API net.AddressInfo { address:
'127.0.0.1', family: 'IPv4', port: 40441 }
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.371Z] INFO (api-server): DCI Lint API reachable http://127.0.0.1:40441
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.371Z] INFO (api-server): Cockpit reachable http://127.0.0.1:37591
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 2> Not Found: not found
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 2>     at
/****/dci-lint/node_modules/express-openapi-validator/src/middlewares/openapi.metadata.ts:58:13
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 2>     at
/****/dci-lint/node_modules/express-openapi-validator/src/openapi.validator.ts:147:18
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 2>     at processTicksAndRejections (node:internal/process/task_queues:95:5)
​ FAIL ​ pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts
 ✖ Error: Request failed with status code 404

  test: pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts
  operator: error
  at: bound
    (/****/dci-lint/node_modules/tape-promise/node_modules/onetime/index.js:30:12)
  stack: >-
    Error: Request failed with status code 404
        at createError (/****/dci-lint/node_modules/axios/lib/core/createError.js:16:15)
        at settle (/****/dci-lint/node_modules/axios/lib/core/settle.js:17:12)
        at IncomingMessage.handleStreamEnd (/****/dci-lint/node_modules/axios/lib/adapters/http.js:269:11)
        at IncomingMessage.emit (node:events:525:35)
        at IncomingMessage.emit (node:domain:489:12)
        at endReadableNT (node:internal/streams/readable:1359:12)
        at processTicksAndRejections (node:internal/process/task_queues:82:21)

pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.501Z] INFO (api-server): Shutting down API server ...
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.501Z] INFO (api-server): Closing HTTP server of the API...
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.502Z] INFO (api-server): Close HTTP server of the API OK
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.502Z] INFO (api-server): Closing HTTP server of the cockpit ...
pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1> [2022-12-21T23:22:50.502Z] INFO (api-server): Close HTTP server of the cockpit OK
​ FAIL ​ pkg/test-cmd-api-server/src/test/typescript/integration/api-server.test.ts 1 failed of 1 3s
 ✖ Error: Request failed with status code 404
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant