From 75c54410a6a2ac033a2d81ba3cac1f5a64c3e6ec Mon Sep 17 00:00:00 2001 From: Benny Powers Date: Tue, 4 Jun 2024 09:21:47 +0300 Subject: [PATCH] test: resolve icon imports --- web-test-runner.config.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/web-test-runner.config.js b/web-test-runner.config.js index 329cde552e..32a1faa76f 100644 --- a/web-test-runner.config.js +++ b/web-test-runner.config.js @@ -10,4 +10,11 @@ export default pfeTestRunnerConfig({ plugins: [ a11ySnapshotPlugin(), ], + middleware: [ + async function(ctx) { + if (ctx.path.match(/@patternfly\/icons\/.*\.js/)) { + ctx.redirect(`/node_modules/${ctx.path}`); + } + }, + ], });