Skip to content
This repository has been archived by the owner on Jan 31, 2024. It is now read-only.

Commit

Permalink
allow browser tests to be runOnce
Browse files Browse the repository at this point in the history
  • Loading branch information
w33ble committed Dec 15, 2016
1 parent 4cfbe28 commit ede52ec
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tasks/test/browser/test_browser_action.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = function (plugin) {
module.exports = function (plugin, opts = {}) {
var execFileSync = require('child_process').execFileSync;

var kbnServerArgs = [
Expand All @@ -7,7 +7,8 @@ module.exports = function (plugin) {
];

var cmd = 'npm';
var args = ['run', 'test:dev', '--'].concat(kbnServerArgs);
var task = (opts.runOnce) ? 'test:browser' : 'test:dev';
var args = ['run', task, '--'].concat(kbnServerArgs);
execFileSync(cmd, args, {
cwd: plugin.kibanaRoot,
stdio: ['ignore', 1, 2]
Expand Down

0 comments on commit ede52ec

Please sign in to comment.