Skip to content

Commit

Permalink
Use glob matching for e2e tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nicksellen committed Dec 4, 2017
1 parent 481f5a6 commit faff50b
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Expand Up @@ -101,6 +101,8 @@
"favicons-webpack-plugin": "0.0.7",
"file-loader": "^1.1.5",
"friendly-errors-webpack-plugin": "^1.6.1",
"glob": "^7.1.2",
"glob-promise": "^3.3.0",
"html-webpack-plugin": "^2.29.0",
"http-proxy": "^1.16.2",
"imports-loader": "^0.7.1",
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions tests/e2e/run.js
@@ -1,5 +1,6 @@
const createTestCafe = require('testcafe')
const { join } = require('path')
const glob = require('glob-promise');

const isCI = process.argv.includes('--ci')
const browsers = isCI ? ['chrome:headless'] : ['chromium'];
Expand All @@ -8,8 +9,7 @@ const browsers = isCI ? ['chrome:headless'] : ['chromium'];
const testcafe = await createTestCafe('localhost')
const runner = await testcafe.createRunner()
const failedCount = await runner
// should pass in test files via args or use some autodiscovery
.src(join(__dirname, 'findStuff.js'))
.src(await glob(join(__dirname, '**/*.e2e.js')))
.browsers(browsers)
.screenshots('e2e-screenshots')
.run({
Expand Down

0 comments on commit faff50b

Please sign in to comment.