@@ -105,15 +105,15 @@ if (onPreparePath) {
105
105
setConf ( conf , 'framework' , 'jasmine2' , 'is set to jasmine2' ) ;
106
106
107
107
const specs =
108
- [ TMPL_specs ] . map ( s => require . resolve ( s ) ) . filter ( s => / ( \b | _ ) ( s p e c | t e s t ) \. j s $ / . test ( s ) ) ;
108
+ [ TMPL_specs ] . map ( s => runfiles . resolve ( s ) ) . filter ( s => / ( \b | _ ) ( s p e c | t e s t ) \. j s $ / . test ( s ) ) ;
109
109
110
110
setConf ( conf , 'specs' , specs , 'are determined by the srcs and deps attribute' ) ;
111
111
112
112
// WEB_TEST_METADATA is configured in rules_webtesting based on value
113
113
// of the browsers attribute passed to karma_web_test_suite
114
114
// We setup the protractor configuration based on the values in this object
115
115
if ( process . env [ 'WEB_TEST_METADATA' ] ) {
116
- const webTestMetadata = require ( process . env [ 'WEB_TEST_METADATA' ] ) ;
116
+ const webTestMetadata = require ( runfiles . resolve ( process . env [ 'WEB_TEST_METADATA' ] ) ) ;
117
117
log_verbose ( `WEB_TEST_METADATA: ${ JSON . stringify ( webTestMetadata , null , 2 ) } ` ) ;
118
118
if ( webTestMetadata [ 'environment' ] === 'local' ) {
119
119
// When a local chrome or firefox browser is chosen such as
@@ -124,8 +124,8 @@ if (process.env['WEB_TEST_METADATA']) {
124
124
const webTestNamedFiles = webTestMetadata [ 'webTestFiles' ] [ 0 ] [ 'namedFiles' ] ;
125
125
const headless = ! process . env [ 'DISPLAY' ] ;
126
126
if ( webTestNamedFiles [ 'CHROMIUM' ] ) {
127
- const chromeBin = require . resolve ( webTestNamedFiles [ 'CHROMIUM' ] ) ;
128
- const chromeDriver = require . resolve ( webTestNamedFiles [ 'CHROMEDRIVER' ] ) ;
127
+ const chromeBin = runfiles . resolve ( webTestNamedFiles [ 'CHROMIUM' ] ) ;
128
+ const chromeDriver = runfiles . resolve ( webTestNamedFiles [ 'CHROMEDRIVER' ] ) ;
129
129
130
130
// The sandbox needs to be disabled, because it causes Chrome to crash on some environments.
131
131
// See: http://chromedriver.chromium.org/help/chrome-doesn-t-start
@@ -147,7 +147,7 @@ if (process.env['WEB_TEST_METADATA']) {
147
147
// TODO(gmagolan): implement firefox support for protractor
148
148
throw new Error ( 'Firefox not yet support by protractor_web_test_suite' ) ;
149
149
150
- // const firefoxBin = require .resolve(webTestNamedFiles['FIREFOX'])
150
+ // const firefoxBin = runfiles .resolve(webTestNamedFiles['FIREFOX'])
151
151
// const args = [];
152
152
// if (headless) {
153
153
// args.push("--headless")
0 commit comments