@@ -247,15 +247,16 @@ function findAndRunE2eTests(filter, outputFile) {
247
247
e2eSpecPaths . forEach ( function ( specPath ) {
248
248
// get all of the examples under each dir where a pcFilename is found
249
249
localExamplePaths = getExamplePaths ( specPath , true ) ;
250
- // Filter by language
251
- localExamplePaths = localExamplePaths . filter ( function ( fn ) {
252
- return fn . match ( '/' + lang + '$' ) != null ;
253
- } ) ;
250
+ // Filter by example name
254
251
if ( filter ) {
255
252
localExamplePaths = localExamplePaths . filter ( function ( fn ) {
256
253
return fn . match ( filter ) != null ;
257
254
} )
258
255
}
256
+ // Filter by language, also supports variations like js-es6
257
+ localExamplePaths = localExamplePaths . filter ( function ( fn ) {
258
+ return fn . match ( '/' + lang + '(?:-[^/]*)?$' ) != null ;
259
+ } ) ;
259
260
localExamplePaths . forEach ( function ( examplePath ) {
260
261
examplePaths . push ( examplePath ) ;
261
262
} )
@@ -1270,7 +1271,7 @@ function apiExamplesWatch(postShredAction) {
1270
1271
}
1271
1272
1272
1273
function devGuideExamplesWatch ( shredOptions , postShredAction , focus ) {
1273
- var watchPattern = focus ? '**/ {' + focus + ',cb-' + focus + '}/**/*.*' : '**/*.*' ;
1274
+ var watchPattern = focus ? '{' + focus + ',cb-' + focus + '}/**/*.*' : '**/*.*' ;
1274
1275
var includePattern = path . join ( shredOptions . examplesDir , watchPattern ) ;
1275
1276
// removed this version because gulp.watch has the same glob issue that dgeni has.
1276
1277
// var excludePattern = '!' + path.join(shredOptions.examplesDir, '**/node_modules/**/*.*');
0 commit comments