refs #261 - attempt at fixing coffeescript based tests/modules
Showing
4 changed files
with
14 additions
and
1 deletions
... | @@ -203,7 +203,7 @@ function bootstrap(global) { | ... | @@ -203,7 +203,7 @@ function bootstrap(global) { |
203 | } | 203 | } |
204 | 204 | ||
205 | // Embedded, up-to-date, validatable & controlable CoffeeScript | 205 | // Embedded, up-to-date, validatable & controlable CoffeeScript |
206 | phantom.injectJs(fs.pathJoin(phantom.casperPath, 'node_modules', 'vendors', 'coffee-script.js')); | 206 | phantom.injectJs(fs.pathJoin(phantom.casperPath, 'modules', 'vendors', 'coffee-script.js')); |
207 | 207 | ||
208 | // custom global CasperError | 208 | // custom global CasperError |
209 | global.CasperError = function CasperError(msg) { | 209 | global.CasperError = function CasperError(msg) { | ... | ... |
tests/suites/modules/csmodule.coffee
0 → 100644
1 | exports.ok = true |
tests/suites/modules/jsmodule.js
0 → 100644
1 | exports.ok = true |
tests/suites/require.js
0 → 100644
1 | /*global casper*/ | ||
2 | /*jshint strict:false*/ | ||
3 | var fs = require('fs'); | ||
4 | var modroot = fs.pathJoin(phantom.casperPath, 'tests', 'suites', 'modules'); | ||
5 | var jsmod = require(fs.pathJoin(modroot, 'jsmodule')); | ||
6 | var csmod = require(fs.pathJoin(modroot, 'csmodule')); | ||
7 | |||
8 | casper.test.assertTrue(jsmod.ok, 'require() patched version can load a js module'); | ||
9 | casper.test.assertTrue(csmod.ok, 'require() patched version can load a coffeescript module'); | ||
10 | |||
11 | casper.test.done(); |
-
Please register or sign in to post a comment