Commit cbb88484 cbb8848409ebda2f07750f66e32a19815314d65e by Nicolas Perriault

fixed test suite runner

1 parent 0c4095fb
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 }
......