You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 23, 2021. It is now read-only.
When the tests run, I see a number of errors logged. However, the build does not fail.
For example, please inspect the yarn run test step of this build.
● Console
console.error
Error: Not implemented: HTMLCanvasElement.prototype.getContext (without installing the canvas npm package)
at module.exports (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jsdom/lib/jsdom/browser/not-implemented.js:9:17)
at HTMLCanvasElementImpl.getContext (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jsdom/lib/jsdom/living/nodes/HTMLCanvasElement-impl.js:42:5)
at HTMLCanvasElement.getContext (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jsdom/lib/jsdom/living/generated/HTMLCanvasElement.js:130:58)
at hasBrowserCanvas (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jspdf/src/libs/png.js:480:36)
at /home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jspdf/src/libs/png.js:489:3
at Object.<anonymous> (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jspdf/src/libs/png.js:28:11)
at Runtime._execModule (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jest-runtime/build/index.js:1299:24)
at Runtime._loadModule (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jest-runtime/build/index.js:898:12)
at Runtime.requireModule (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jest-runtime/build/index.js:746:10)
at Runtime.requireModuleOrMock (/home/runner/work/backstage-plugin-buildkite/backstage-plugin-buildkite/node_modules/jest-runtime/build/index.js:919:21) undefined
at VirtualConsole.<anonymous> (../node_modules/jsdom/lib/jsdom/virtual-console.js:29:45)
at module.exports (../node_modules/jsdom/lib/jsdom/browser/not-implemented.js:12:26)
at HTMLCanvasElementImpl.getContext (../node_modules/jsdom/lib/jsdom/living/nodes/HTMLCanvasElement-impl.js:42:5)
at HTMLCanvasElement.getContext (../node_modules/jsdom/lib/jsdom/living/generated/HTMLCanvasElement.js:130:58)
at hasBrowserCanvas (../node_modules/jspdf/src/libs/png.js:480:36)
at ../node_modules/jspdf/src/libs/png.js:489:3
at Object.<anonymous> (../node_modules/jspdf/src/libs/png.js:28:11)
The text was updated successfully, but these errors were encountered:
These tests are executing in the testing environment jsdom which emulates most of the browser. It doesn't emulate the canvas element and one of the libraries in the dependency tree (jspdf) checks for that. We can get rid of the errors in two ways:
polyfill canvas elements in the testing environment
When the tests run, I see a number of errors logged. However, the build does not fail.
For example, please inspect the
yarn run test
step of this build.The text was updated successfully, but these errors were encountered: