fixed test suite runner
Showing
1 changed file
with
3 additions
and
3 deletions
1 | if (!phantom.casperPath || !phantom.Casper) { | 1 | if (!phantom.casperLoaded) { |
2 | console.log('This script must be invoked using the casperjs executable'); | 2 | console.log('This script must be invoked using the casperjs executable'); |
3 | phantom.exit(1); | 3 | phantom.exit(1); |
4 | } | 4 | } |
... | @@ -25,8 +25,8 @@ phantom.Casper.extend({ | ... | @@ -25,8 +25,8 @@ phantom.Casper.extend({ |
25 | 25 | ||
26 | (function(casper) { | 26 | (function(casper) { |
27 | var tests = []; | 27 | var tests = []; |
28 | if (phantom.args.length > 2 && fs.isFile(phantom.args[2])) { | 28 | if (phantom.casperArgs.args.length > 2 && fs.isFile(phantom.casperArgs.args[2])) { |
29 | tests = [phantom.args[2]]; | 29 | tests = [phantom.casperArgs.args[2]]; |
30 | } else { | 30 | } else { |
31 | tests = [fs.absolute(fs.pathJoin(phantom.casperPath, 'tests', 'suites'))]; | 31 | tests = [fs.absolute(fs.pathJoin(phantom.casperPath, 'tests', 'suites'))]; |
32 | } | 32 | } | ... | ... |
-
Please register or sign in to post a comment