Show More
@@ -17,7 +17,7 b' casper.notebook_test(function () {' | |||||
17 | this.then(function () { |
|
17 | this.then(function () { | |
18 | if (this.slimerjs) { |
|
18 | if (this.slimerjs) { | |
19 | // When running in xvfb, the Slimer window doesn't always have focus |
|
19 | // When running in xvfb, the Slimer window doesn't always have focus | |
20 |
// immediately. By clicking on a new element on the page we c |
|
20 | // immediately. By clicking on a new element on the page we can force | |
21 | // it to gain focus. |
|
21 | // it to gain focus. | |
22 | this.click_cell_editor(1); |
|
22 | this.click_cell_editor(1); | |
23 | this.click_cell_editor(0); |
|
23 | this.click_cell_editor(0); |
@@ -464,7 +464,7 b' casper.notebook_test = function(test) {' | |||||
464 | } |
|
464 | } | |
465 |
|
465 | |||
466 | // Make sure to remove the onbeforeunload callback. This callback is |
|
466 | // Make sure to remove the onbeforeunload callback. This callback is | |
467 |
// respons |
|
467 | // responsible for the "Are you sure you want to quit?" type messages. | |
468 | // PhantomJS ignores these prompts, SlimerJS does not which causes hangs. |
|
468 | // PhantomJS ignores these prompts, SlimerJS does not which causes hangs. | |
469 | this.then(function(){ |
|
469 | this.then(function(){ | |
470 | this.evaluate(function(){ |
|
470 | this.evaluate(function(){ |
@@ -257,12 +257,10 b' class JSController(TestController):' | |||||
257 | def wait(self, *pargs, **kwargs): |
|
257 | def wait(self, *pargs, **kwargs): | |
258 | """Wait for the JSController to finish""" |
|
258 | """Wait for the JSController to finish""" | |
259 | ret = super(JSController, self).wait(*pargs, **kwargs) |
|
259 | ret = super(JSController, self).wait(*pargs, **kwargs) | |
260 |
# If this is a SlimerJS controller, |
|
260 | # If this is a SlimerJS controller, check the captured stdout for | |
|
261 | # errors. Otherwise, just return the return code. | |||
261 | if self.engine == 'slimerjs': |
|
262 | if self.engine == 'slimerjs': | |
262 | # Echo captured output. |
|
|||
263 | stdout = bytes_to_str(self.stdout) |
|
263 | stdout = bytes_to_str(self.stdout) | |
264 | print(stdout) |
|
|||
265 | # Return True if a failure occured. |
|
|||
266 | return self.slimer_failure.search(strip_ansi(stdout)) |
|
264 | return self.slimer_failure.search(strip_ansi(stdout)) | |
267 | else: |
|
265 | else: | |
268 | return ret |
|
266 | return ret | |
@@ -376,7 +374,7 b' def prepare_controllers(options):' | |||||
376 | else: |
|
374 | else: | |
377 | js_testgroups = all_js_groups() |
|
375 | js_testgroups = all_js_groups() | |
378 |
|
376 | |||
379 |
engine = ' |
|
377 | engine = 'slimerjs' if options.slimerjs else 'phantomjs' | |
380 | c_js = [JSController(name, engine=engine) for name in js_testgroups] |
|
378 | c_js = [JSController(name, engine=engine) for name in js_testgroups] | |
381 | c_py = [PyTestController(name, options) for name in py_testgroups] |
|
379 | c_py = [PyTestController(name, options) for name in py_testgroups] | |
382 |
|
380 |
General Comments 0
You need to be logged in to leave comments.
Login now