Skip to content
This repository was archived by the owner on May 30, 2019. It is now read-only.

Commit 6001e7f

Browse files
committed
instructions for manual phantomjs if necessary
As reported in #675, manual install of phantomjs may be necessary in caseswhere it is not installed properly by the repository-wide npm install process. Add instructions to README for cases where this happens.
1 parent ce02eae commit 6001e7f

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

README-JavaScript.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,32 @@ The reasons for this are documented in https://support.saucelabs.com/entries/274
190190

191191
Please see [Node.js and npm Tips for Samplestack Development](https://github.com/marklogic/marklogic-samplestack/wiki/Node.js-and-npm-Tips-for-Samplestack-Development).
192192

193+
## OSX Workaround for Improperly Installed `phantomjs` Module
194+
195+
In some cases, the following may be seen when unit tests are run in the terminal:
196+
197+
```
198+
...
199+
[18:14:41] Starting 'unit'...
200+
201+
Unit Tests:
202+
/path/to/marklogic-samplestack/node_modules/phantomjs/lib/location.js:1
203+
(function (exports, require, module, __filename, __dirname) {
204+
^
205+
TypeError: Bad argument
206+
at ChildProcess.spawn (child_process.js:936:24)
207+
at exports.spawn (child_process.js:736:9)
208+
...
209+
[18:14:43] Error in plugin 'gulp-mocha-phantomjs'
210+
test failed
211+
```
212+
213+
This error occurs if the `phantomjs` library did not install properly. To work around this, the developer may manually install `phantomjs` (from the marklogic-samplestack repostiory root directory):
214+
215+
```
216+
> $ npm install phantomjs
217+
```
218+
193219
## OSX Workaround for Watch Mode
194220

195221
In general your "watch" process will be faster on Mac/OSX computers if you raise the limit of the number

0 commit comments

Comments
 (0)