Skip to content

Commit

Permalink
Remove the esmodule helpers ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
benjervis committed Dec 12, 2024
1 parent f7c6e54 commit ec74432
Showing 1 changed file with 2 additions and 13 deletions.
15 changes: 2 additions & 13 deletions packages/core/test-utils/src/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -620,21 +620,10 @@ export function assertBundles(
return false;
}

// If we aren't explicitly expecting esmodule-helpers, then ignore it
let assetsToCompare = actualBundle.assets;
if (
expectedBundle.assets.indexOf(esmoduleHelpersName) === -1 &&
actualBundle.assets.indexOf(esmoduleHelpersName) !== -1
) {
assetsToCompare = actualBundle.assets.filter(
(a) => a !== 'esmodule-helpers.js',
);
}

return (
expectedBundle.assets &&
expectedBundle.assets.length === assetsToCompare.length &&
expectedBundle.assets.every((a, i) => a === assetsToCompare[i])
expectedBundle.assets.length === actualBundle.assets.length &&
expectedBundle.assets.every((a, i) => a === actualBundle.assets[i])
);
});

Expand Down

0 comments on commit ec74432

Please sign in to comment.