File tree 2 files changed +9
-17
lines changed
2 files changed +9
-17
lines changed Original file line number Diff line number Diff line change @@ -57,7 +57,10 @@ writer.makeDir('build/docs/', true).then(function() {
57
57
fileFutures . push ( writer . output ( 'partials/' + doc . section + '/' + id + '.html' , doc . html ( ) ) ) ;
58
58
// If it has a sample Protractor test, output that as well.
59
59
if ( doc . protractorTests . length ) {
60
- fileFutures . push ( writer . output ( 'ptore2e/' + doc . section + '/' + id + '_test.js' , ngdoc . writeProtractorTest ( doc ) ) ) ;
60
+ fileFutures . push ( writer . output ( 'ptore2e/' + doc . section + '/' + id + '.jquery_test.js' ,
61
+ ngdoc . writeProtractorTest ( doc , 'index-jq-nocache.html#!/' ) ) ) ;
62
+ fileFutures . push ( writer . output ( 'ptore2e/' + doc . section + '/' + id + '.jqlite_test.js' ,
63
+ ngdoc . writeProtractorTest ( doc , 'index-nocache.html#!/' ) ) ) ;
61
64
}
62
65
} ) ;
63
66
Original file line number Diff line number Diff line change @@ -1110,28 +1110,17 @@ function scenarios(docs){
1110
1110
}
1111
1111
}
1112
1112
1113
- function writeProtractorTest ( doc ) {
1113
+ function writeProtractorTest ( doc , pathPrefix ) {
1114
1114
var lines = [ ] ;
1115
1115
lines . push ( 'describe("' + doc . section + '/' + doc . id + '", function() {' ) ;
1116
- lines . push ( ' describe("angular+jqLite", function() {' )
1117
- lines . push ( ' beforeEach(function() {' ) ;
1118
- lines . push ( ' browser.get("index-nocache.html#!/' + doc . section + '/' + doc . id + '");' ) ;
1119
- lines . push ( ' });' ) ;
1120
- lines . push ( '' ) ;
1121
- doc . protractorTests . forEach ( function ( test ) {
1122
- lines . push ( indentCode ( trim ( test ) , 4 ) ) ;
1123
- lines . push ( '' ) ;
1124
- } ) ;
1116
+ lines . push ( ' beforeEach(function() {' ) ;
1117
+ lines . push ( ' browser.get("' + pathPrefix + doc . section + '/' + doc . id + '");' ) ;
1125
1118
lines . push ( ' });' ) ;
1126
- lines . push ( ' describe("angular+jQuery", function() {' )
1127
- lines . push ( ' beforeEach(function() {' ) ;
1128
- lines . push ( ' browser.get("index-jq-nocache.html#!/' + doc . section + '/' + doc . id + '");' ) ;
1129
- lines . push ( ' });' ) ;
1119
+ lines . push ( '' ) ;
1130
1120
doc . protractorTests . forEach ( function ( test ) {
1131
- lines . push ( indentCode ( trim ( test ) , 4 ) ) ;
1121
+ lines . push ( indentCode ( trim ( test ) , 0 ) ) ;
1132
1122
lines . push ( '' ) ;
1133
1123
} ) ;
1134
- lines . push ( ' });' ) ;
1135
1124
lines . push ( '});' ) ;
1136
1125
lines . push ( '' ) ;
1137
1126
return lines . join ( '\n' ) ;
You can’t perform that action at this time.
0 commit comments