Questions tagged [spookyjs]

SpookyJS makes it possible to drive CasperJS suites from Node.js. At a high level, Spooky accomplishes this by spawning Casper as a child process and controlling it via RPC.

SpookyJS makes it possible to drive CasperJS suites from Node.js. At a high level, Spooky accomplishes this by spawning Casper as a child process and controlling it via RPC.

Specifically, each Spooky instance spawns a child Casper process that runs a bootstrap script. The bootstrap script sets up a JSON-RPC server that listens for commands from the parent Spooky instance over a transport (either HTTP or stdin). The script also sets up a JSON-RPC client that sends events to the parent Spooky instance via stdout.

Source: https://github.com/WaterfallEngineering/SpookyJS

See also:

62 questions
2
votes
2 answers

SpookyJS: Console.log Doesn't Work Inside Then

try { var Spooky = require("spooky"); } catch (e) { console.log(e); } var spooky = new Spooky({ capser: { logLevel: "debug", verbose: true }, child: { command: "./casperjs/bin/casperjs", port: 8081, spooky_lib:…
A. Duff
  • 4,097
  • 7
  • 38
  • 69
2
votes
0 answers

SpookyJS each() method

In SpookyJS, is there an "each" function equivalent to that of Casper's? http://casperjs.readthedocs.org/en/latest/modules/casper.html#each
maxko87
  • 2,892
  • 4
  • 28
  • 43
2
votes
2 answers

Error running sample code using Spooky.js

I am new to the whole stack of node.js, phantom.js, casper.js and spooky.js. I have everything installed (in Windows), with PATH updated and followed this example: https://github.com/WaterfallEngineering/SpookyJS I got this…
HP.
  • 19,226
  • 53
  • 154
  • 253
1
vote
0 answers

passing socket.io instance to spooky

in my code i have a socket.io server and i need clients to send signal to server and than start spooky ... after starting spooky i need to send back and forth some data from server to client via io so i need socket.io instance inside spooky here is…
hretic
  • 999
  • 9
  • 36
  • 78
1
vote
0 answers

Webpack with Phantom/Casper/Spooky: Unable to Open File

My Spooky/Casper/Phantom project was working just fine. Then I tried to involve Webpack. When I run the program, I get: CasperError: Can't find module node_modules/spooky/lib/bootstrap/emit [ { file: 'phantomjs://code/bootstrap.js', line: 297, …
Louis Cruz
  • 1,703
  • 2
  • 15
  • 20
1
vote
1 answer

Why CasperJS fills text input with [object Object]

I use this code to fill text input spooky.then([{question: question}, function(question) { this.fill('form[name="askmore"]', { questionask: question}, false); }]); I have a valid sting in question. Here's a form markup:
dKab
  • 2,658
  • 5
  • 20
  • 35
1
vote
0 answers

Solve captcha with spookyjs (casperjs)

I'm trying to write a test for my site, by logging into it and performing some actions. I've got a script that is SO CLOSE to working but there is one key flaw which i haven't been able to circumvent. See logic below var phantom =…
Shan Robertson
  • 2,742
  • 3
  • 25
  • 43
1
vote
1 answer

Understanding Scopes in Spooky JS

This implementation of SpookyJS is really spooky. While using Gulp to run Mocha + SpookyJS tests, I am unable to see most console log output. I have been following the Quickstart steps on SpookyJS's github page. Why can't I see these console log…
GracefulCode
  • 141
  • 7
1
vote
0 answers

CasperJS with SpookyJS hanging after getting page content

I am using CasperJS and SpookyJS to navigate to a page, parse the page HTML, and then take some action depending on the HTML of the parsed page. However, pulling HTML from the page blocks all further spookyInstance.then calls from executing.…
mattmattmatt
  • 965
  • 3
  • 15
  • 29
1
vote
0 answers

How to load a webpage after spooky.js is initialized

Is it possible to chain missions to spookyjs after initialization? Something like this: Spooky = require('spooky'); var spooky = new Spooky({ child: { transport: 'http' }, casper: { logLevel: 'debug', verbose:…
someone235
  • 567
  • 2
  • 7
  • 21
1
vote
0 answers

How to continue at particular step - spookyjs?

I am using spookyjs to test my application. Question Is there anyway to enforce the spookyJs to start at particular step? How to force start at particular step spookyJs? Example SpookyJs will run step by step, Suppose some connection error happened…
karthick
  • 5,998
  • 12
  • 52
  • 90
1
vote
1 answer

Does SpookyJS support https web pages?

I'm new to SpookyJS. In the hello.js example which has been provided i tried changing the url http://en.wikipedia.org/wiki/Spooky_the_Tuff_Little_Ghost to https://www.twitter.com/ or www.facebook.com with https none of these seem to be…
Hasan 0
  • 29
  • 7
1
vote
1 answer

Express & Casper: Can't set headers after they are sent

I'm getting a Can't set headers after they are sent error when trying to run a SpookyJS (a driver for CasperJS) script after posted to a URL. I've found several other posts about people running this issue with Express and it has to do with the…
Trevan Hetzel
  • 1,371
  • 7
  • 21
  • 42
1
vote
3 answers

ReferenceError: Can't find variable with SpookyJS

I try to call an external function in SpookyJS by doing the same thing than in the wiki: https://github.com/WaterfallEngineering/SpookyJS/wiki/Introduction But when I try the following code, I have this error: ReferenceError: Can't find variable:…
Jean Lebrument
  • 5,079
  • 8
  • 33
  • 67
1
vote
0 answers

spookyjs stops running without error

I'm building a tool that logs into a website and visits a high number of pages that are listed in an array. Everytime I run this CasperJS seems to hang when visiting the 36th link. I tried removing the 36th link, but then it just hangs at the next…
Bunker
  • 1,040
  • 3
  • 12
  • 25