Release PR #151
Annotations
7 errors
|
Request tests > should throw error when response has no data property:
test/request.spec.ts#L115
Error: expect(received).rejects.toThrowError()
Received function did not throw
at Object.toThrowError (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/expect/build/index.js:241:22)
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:124:48
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:115:74)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
Request tests > should throw error when response is null:
test/request.spec.ts#L127
Error: expect(received).rejects.toThrowError()
Received function did not throw
at Object.toThrowError (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/expect/build/index.js:241:22)
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:135:48
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:127:61)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
Request tests > should handle non-Error objects as errors when they have message property:
test/request.spec.ts#L279
Error: expect(received).rejects.toThrowError(expected)
Expected substring: "Internal Server Error"
Received function did not throw
at Object.toThrowError (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/expect/build/index.js:241:22)
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:290:48
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:279:94)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
Request tests > should handle non-Error objects as errors when they have no message property:
test/request.spec.ts#L293
Error: expect(received).rejects.toThrowError(expected)
Expected substring: "{\"status\":500,\"code\":\"SERVER_ERROR\"}"
Received function did not throw
at Object.toThrowError (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/expect/build/index.js:241:22)
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:304:48
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/request.spec.ts:293:97)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
retryResponseErrorHandler > should create and throw custom error for non-retryable responses:
test/retryPolicy/delivery-sdk-handlers.spec.ts#L630
Error: expect(received).toBe(expected) // Object.is equality
Expected: 400
Received: undefined
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:651:34
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:630:85)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
retryResponseErrorHandler > should create custom error for 500 internal server error:
test/retryPolicy/delivery-sdk-handlers.spec.ts#L659
Error: expect(received).toBe(expected) // Object.is equality
Expected: 500
Received: undefined
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:680:34
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:659:77)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|
|
retryResponseErrorHandler > should handle custom error for 422 unprocessable entity:
test/retryPolicy/delivery-sdk-handlers.spec.ts#L688
Error: expect(received).toBe(expected) // Object.is equality
Expected: 422
Received: undefined
at /home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:712:34
at Generator.next (<anonymous>)
at /home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:170:75
at new Promise (<anonymous>)
at Object.__awaiter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/tslib/tslib.js:166:16)
at Object.<anonymous> (/home/runner/work/contentstack-js-core/contentstack-js-core/test/retryPolicy/delivery-sdk-handlers.spec.ts:688:76)
at Promise.then.completed (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:333:28)
at new Promise (<anonymous>)
at callAsyncCircusFn (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/utils.js:259:10)
at _callCircusTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:277:40)
at _runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:209:3)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:97:9)
at _runTestsForDescribeBlock (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:91:9)
at run (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/run.js:31:3)
at runAndTransformResultsToJestFormat (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapterInit.js:135:21)
at jestAdapter (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:92:19)
at runTestInternal (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:411:16)
at runTest (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/runTest.js:499:34)
at Object.worker (/home/runner/work/contentstack-js-core/contentstack-js-core/node_modules/jest-runner/build/testWorker.js:133:12)
|