diff --git a/aio/tools/examples/run-example-e2e.js b/aio/tools/examples/run-example-e2e.js index 63d92f1d31..ba6368401b 100644 --- a/aio/tools/examples/run-example-e2e.js +++ b/aio/tools/examples/run-example-e2e.js @@ -325,7 +325,7 @@ function getE2eSpecs(basePath, filter) { // Find all e2e specs in a given example folder. function getE2eSpecsFor(basePath, specFile, filter) { // Only get spec file at the example root. - const e2eSpecGlob = `${filter ? '*' + filter + '*' : '*'}/${specFile}`; + const e2eSpecGlob = `${filter ? `*${filter}*` : '*'}/${specFile}`; return globby(e2eSpecGlob, {cwd: basePath, nodir: true}) .then( paths => paths.filter(file => !IGNORED_EXAMPLES.some(ignored => file.startsWith(ignored)))