build(bazel): fix runfiles resolve in karma-saucelabs.js after $location => $rootpath cleanup (#36511)

This wasn't caught by CI on the PR as this binary is only run once daily via a monitor job.

PR Close #36511
This commit is contained in:
Greg Magolan 2020-04-08 08:28:03 -07:00 committed by Kara Erickson
parent a8978ebf8e
commit 03f2f1ae47
1 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@
const shell = require('shelljs');
const karmaBin = require.resolve('karma/bin/karma');
const runfiles = require(process.env['BAZEL_NODE_RUNFILES_HELPER']);
const sauceService = runfiles.resolve(process.argv[2]);
const sauceService = runfiles.resolveWorkspaceRelative(process.argv[2]);
process.argv = [
process.argv[0],
karmaBin,
@ -61,7 +61,7 @@ try {
}
console.error(`Launching karma ${karmaBin}...`);
module.constructor._load(karmaBin, this, /*isMain=*/true);
module.constructor._load(karmaBin, this, /*isMain=*/ true);
} catch (e) {
console.error(e.stack || e);
process.exit(1);