File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
vendor/jasmine-jsreporter Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 11document . write ( '<style> @import "../vendor/jasmine/jasmine.css?_=' + ( + new Date ) . toString ( 36 ) + '"; </style>' ) ;
22
33; ( function ( env ) {
4- env . addReporter ( new jasmine . HtmlReporter ) ;
4+ var htmlReporter = new jasmine . HtmlReporter ( ) ;
5+ env . addReporter ( htmlReporter ) ;
6+ env . specFilter = function ( spec ) {
7+ return htmlReporter . specFilter ( spec ) ;
8+ } ;
9+
510 // Clean up any nodes the previous test might have added.
611 env . afterEach ( function ( ) {
712 harness . removeNextSiblings ( document . body ) ;
Original file line number Diff line number Diff line change 113113 reportSpecResults : function ( spec ) {
114114 // Finish timing this spec and calculate duration/delta (in sec)
115115 spec . finishedAt = new Date ( ) ;
116- spec . durationSec = elapsedSec ( spec . startedAt . getTime ( ) , spec . finishedAt . getTime ( ) ) ;
116+ // If the spec was skipped, reportSpecStarting is never called and spec.startedAt is undefined
117+ spec . durationSec = spec . startedAt ? elapsedSec ( spec . startedAt . getTime ( ) , spec . finishedAt . getTime ( ) ) : 0 ;
117118 } ,
118119
119120 reportSuiteResults : function ( suite ) {
You can’t perform that action at this time.
0 commit comments