@@ -7,9 +7,9 @@ var fs = require('fs');
77var validateFile = function ( ) {
88 try {
99 var content = fs . readFileSync ( browser . params . profileSavePath , 'utf8' ) ;
10- // TODO(hankduan): This check not very useful. Ideally we want to validate
11- // that the file contains all the events that we are looking for. Pending
12- // on data transformer.
10+ // TODO(hankduan): This check is not very useful. Ideally we want to
11+ // validate that the file contains all the events that we are looking for.
12+ // Pending on data transformer.
1313 expect ( content ) . toContain ( 'forceGC' ) ;
1414 // Delete file
1515 fs . unlinkSync ( browser . params . profileSavePath ) ;
@@ -25,22 +25,18 @@ var validateFile = function() {
2525} ;
2626
2727describe ( 'firefox extension' , function ( ) {
28+ var TEST_URL = 'http://localhost:8001/examples/src/hello_world/index.html' ;
29+
2830 it ( 'should measure performance' , function ( ) {
2931 browser . sleep ( 3000 ) ; // wait for extension to load
3032
31- browser . driver . get ( 'http://www.angularjs.org' ) ;
33+ browser . driver . get ( TEST_URL ) ;
3234
3335 browser . executeScript ( 'window.startProfiler()' )
3436 . then ( function ( ) { console . log ( 'started measuring perf' ) ; } ) ;
3537
3638 browser . executeScript ( 'window.forceGC()' ) ;
3739
38- // Run some commands
39- element ( by . model ( 'yourName' ) ) . sendKeys ( 'Hank' ) ;
40- expect ( element ( by . binding ( 'yourName' ) ) . getText ( ) ) . toEqual ( 'Hello Hank!' ) ;
41-
42- browser . executeScript ( 'window.forceGC()' ) ;
43-
4440 var script = 'window.stopAndRecord("' + browser . params . profileSavePath + '")' ;
4541 browser . executeScript ( script ) . then ( function ( ) { console . log ( 'stopped measuring perf' ) ; } ) ;
4642
0 commit comments