File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -177,7 +177,7 @@ function launchBrowser(browser, path) {
177177
178178function launchBrowsers ( config , browser ) {
179179 setTimeout ( function ( ) {
180- if ( Object . prototype . toString . call ( config . test_path ) === '[object Array]' ) {
180+ if ( Array . isArray ( config . test_path ) ) {
181181 config . multipleTest = config . test_path . length > 1 ? true : false ;
182182 launchBrowser ( browser , config . test_path [ 0 ] ) ;
183183 } else {
@@ -276,7 +276,7 @@ function runTests() {
276276 launchServer ( ) ;
277277 tunnel = new Tunnel ( config . key , serverPort , config . tunnelIdentifier , function ( ) {
278278 statusPoller . start ( ) ;
279- var total_runs = config . browsers . length * ( Object . prototype . toString . call ( config . test_path ) === '[object Array]' ? config . test_path . length : 1 ) ;
279+ var total_runs = config . browsers . length * ( Array . isArray ( config . test_path ) ? config . test_path . length : 1 ) ;
280280 logger . info ( 'Launching ' + config . browsers . length + ' worker(s) for ' + total_runs + ' run(s).' ) ;
281281 browsers . forEach ( function ( browser ) {
282282 if ( browser . browser_version === 'latest' ) {
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ var formatPath = function(path) {
7373
7474config . tunnelIdentifier = process . env . TUNNEL_ID || process . env . TRAVIS_JOB_ID || process . env . TRAVIS_BUILD_ID ;
7575
76- if ( Object . prototype . toString . call ( config . test_path ) === '[object Array]' ) {
76+ if ( Array . isArray ( config . test_path ) ) {
7777 config . test_path . forEach ( function ( path ) {
7878 path = formatPath ( path ) ;
7979 } ) ;
You can’t perform that action at this time.
0 commit comments