Closed rochejul closed 10 years ago
Hi,
I defined the engine option onto the grunt task. However, I can see the followwing error:
>> Engine phantomjs not available. [phantomjs,slimerjs]
When we look into the casper.js file, we can see the following code:
if (self.supportedEngines.indexOf(options['engine'])) { spawnOpts.push('--engine=' + options['engine']); } else { grunt.log.warn('Engine ' + options['engine'] + ' not available. [' + self.supportedEngines.join(',') + ']'); }
if the 'indexOf' returns 0, the condition will fail (like '', null, undefined, false). So, we have to replace with the following code:
if (self.supportedEngines.indexOf(options['engine']) >= 0) { spawnOpts.push('--engine=' + options['engine']); } else { grunt.log.warn('Engine ' + options['engine'] + ' not available. [' + self.supportedEngines.join(',') + ']'); }
Thank for you feedbacks
Cheers
Julien Roche
ahh, looks like a late night oversight. I have fixed it and published 0.3.5.. Thank you for pointing this out.
Hi,
I defined the engine option onto the grunt task. However, I can see the followwing error:
When we look into the casper.js file, we can see the following code:
if the 'indexOf' returns 0, the condition will fail (like '', null, undefined, false). So, we have to replace with the following code:
Thank for you feedbacks
Cheers
Julien Roche