Skip to content

Commit

Permalink
Use both --output-path and --output-filename
Browse files Browse the repository at this point in the history
  • Loading branch information
Rob--W committed Oct 14, 2020
1 parent c3b8a79 commit a85b86f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scripts/run-module-bundlers-smoketests.js
Expand Up @@ -8,7 +8,10 @@ Test webextension-polyfill bundled with webpack
===============================================`);

process.env.TEST_BUNDLED_POLYFILL = "/tmp/webpack-bundle.js";
result = shell.exec(`webpack --mode production --entry ./test/fixtures/bundle-entrypoint.js --output-filename ${process.env.TEST_BUNDLED_POLYFILL}`).code ||
const webpackOutputDir = process.env.TEST_BUNDLED_POLYFILL.replace(/\/[^/]+$/, "");
const webpackOutputFilename = process.env.TEST_BUNDLED_POLYFILL.replace(/^.*\//, "");

result = shell.exec(`webpack --mode production --entry ./test/fixtures/bundle-entrypoint.js --output-path ${webpackOutputDir} --output-filename ${webpackOutputFilename}`).code ||
shell.exec("npm run test").code || result;

console.log(`
Expand Down

0 comments on commit a85b86f

Please sign in to comment.