Commit f20f259d f20f259d68dec0337c7ce58960c02329527a7fea by Nicolas Perriault

better naming of pre/post processing closures - refs #231

1 parent 36ca5058
...@@ -725,15 +725,15 @@ var Tester = function Tester(casper, options) { ...@@ -725,15 +725,15 @@ var Tester = function Tester(casper, options) {
725 if (arguments.length === 0) { 725 if (arguments.length === 0) {
726 throw new CasperError("runSuites() needs at least one path argument"); 726 throw new CasperError("runSuites() needs at least one path argument");
727 } 727 }
728 this.loadIncludes.includes.forEach(function(include) { 728 this.loadIncludes.includes.forEach(function _forEachInclude(include) {
729 phantom.injectJs(include); 729 phantom.injectJs(include);
730 }); 730 });
731 731
732 this.loadIncludes.pre.forEach(function(include) { 732 this.loadIncludes.pre.forEach(function _forEachPreTest(preTestFile) {
733 testFiles = testFiles.concat(include); 733 testFiles = testFiles.concat(preTestFile);
734 }); 734 });
735 735
736 Array.prototype.forEach.call(arguments, function _forEach(path) { 736 Array.prototype.forEach.call(arguments, function _forEachArgument(path) {
737 if (!fs.exists(path)) { 737 if (!fs.exists(path)) {
738 self.bar(f("Path %s doesn't exist", path), "RED_BAR"); 738 self.bar(f("Path %s doesn't exist", path), "RED_BAR");
739 } 739 }
...@@ -744,8 +744,8 @@ var Tester = function Tester(casper, options) { ...@@ -744,8 +744,8 @@ var Tester = function Tester(casper, options) {
744 } 744 }
745 }); 745 });
746 746
747 this.loadIncludes.post.forEach(function(include) { 747 this.loadIncludes.post.forEach(function _forEachPostTest(postTestFile) {
748 testFiles = testFiles.concat(include); 748 testFiles = testFiles.concat(postTestFile);
749 }); 749 });
750 750
751 if (testFiles.length === 0) { 751 if (testFiles.length === 0) {
......