diff --git a/.changeset/smooth-ducks-kneel.md b/.changeset/smooth-ducks-kneel.md new file mode 100644 index 00000000..2245bfc6 --- /dev/null +++ b/.changeset/smooth-ducks-kneel.md @@ -0,0 +1,9 @@ +--- +"@ima/plugin-testing-integration": patch +--- + +Fix File class override in jsdom tests + +- **What?** Fix File class override in jsdom tests +- **Why?** Use correct global File class in jsdom +- **How?** Nothing. diff --git a/packages/plugin-testing-integration/src/app.js b/packages/plugin-testing-integration/src/app.js index e97ac663..533c9d15 100644 --- a/packages/plugin-testing-integration/src/app.js +++ b/packages/plugin-testing-integration/src/app.js @@ -90,6 +90,7 @@ async function initImaApp(bootConfigMethods = {}) { // we should switch to `global-jsdom`, or take its implementation // as an inspiration for our own implementation global.CustomEvent = window.CustomEvent; // Hotfix for Node 19+, we can remove this once we switch to `global-jsdom` + global.File = window.File; // Hotfix for Node 19+, we can remove this once we switch to `global-jsdom` // set debug before IMA env debug global.$Debug = true;