@@ -201,7 +201,7 @@ function Karma (updater, socket, iframe, opener, navigator, location, document)
201
201
}
202
202
203
203
socket . emit ( 'karma_error' , message )
204
- self . updater . updateTestStatus ( ` karma_error ${ message } ` )
204
+ self . updater . updateTestStatus ( ' karma_error ' + message )
205
205
this . complete ( )
206
206
return false
207
207
}
@@ -250,8 +250,9 @@ function Karma (updater, socket, iframe, opener, navigator, location, document)
250
250
251
251
// A test could have incorrectly issued a navigate. Wait one turn
252
252
// to ensure the error from an incorrect navigate is processed.
253
- setTimeout ( ( ) => {
254
- if ( this . config . clearContext ) {
253
+ var config = this . config
254
+ setTimeout ( function ( ) {
255
+ if ( config . clearContext ) {
255
256
navigateContextTo ( 'about:blank' )
256
257
}
257
258
@@ -384,7 +385,7 @@ function StatusUpdater (socket, titleElement, bannerElement, browsersElement) {
384
385
if ( ! titleElement || ! bannerElement ) {
385
386
return
386
387
}
387
- titleElement . textContent = ` Karma v ${ VERSION } - ${ connectionText } ; test: ${ testText } ; ${ pingText } `
388
+ titleElement . textContent = ' Karma v ' + VERSION + ' - ' + connectionText + ' ; test: ' + testText + '; ' + pingText
388
389
bannerElement . className = connectionText === 'connected' ? 'online' : 'offline'
389
390
}
390
391
@@ -401,32 +402,32 @@ function StatusUpdater (socket, titleElement, bannerElement, browsersElement) {
401
402
updateBanner ( )
402
403
}
403
404
404
- socket . on ( 'connect' , ( ) => {
405
+ socket . on ( 'connect' , function ( ) {
405
406
updateConnectionStatus ( 'connected' )
406
407
} )
407
- socket . on ( 'disconnect' , ( ) => {
408
+ socket . on ( 'disconnect' , function ( ) {
408
409
updateConnectionStatus ( 'disconnected' )
409
410
} )
410
- socket . on ( 'reconnecting' , ( sec ) => {
411
- updateConnectionStatus ( ` reconnecting in ${ sec } seconds` )
411
+ socket . on ( 'reconnecting' , function ( sec ) {
412
+ updateConnectionStatus ( ' reconnecting in ' + sec + ' seconds' )
412
413
} )
413
- socket . on ( 'reconnect' , ( ) => {
414
+ socket . on ( 'reconnect' , function ( ) {
414
415
updateConnectionStatus ( 'reconnected' )
415
416
} )
416
- socket . on ( 'reconnect_failed' , ( ) => {
417
+ socket . on ( 'reconnect_failed' , function ( ) {
417
418
updateConnectionStatus ( 'reconnect_failed' )
418
419
} )
419
420
420
421
socket . on ( 'info' , updateBrowsersInfo )
421
- socket . on ( 'disconnect' , ( ) => {
422
+ socket . on ( 'disconnect' , function ( ) {
422
423
updateBrowsersInfo ( [ ] )
423
424
} )
424
425
425
- socket . on ( 'ping' , ( ) => {
426
+ socket . on ( 'ping' , function ( ) {
426
427
updatePingStatus ( 'ping...' )
427
428
} )
428
- socket . on ( 'pong' , ( latency ) => {
429
- updatePingStatus ( ` ping ${ latency } ms` )
429
+ socket . on ( 'pong' , function ( latency ) {
430
+ updatePingStatus ( ' ping ' + latency + 'ms' )
430
431
} )
431
432
432
433
return { updateTestStatus : updateTestStatus }
0 commit comments