/home/main/projects/node_modules/tobi/lib/browser.js:421
var elems = this.context.find(selector).filter(function(){
^
TypeError: Object function (selector, fn){
var prev = this.context;
this.context = this.context.find(selector);
fn();
this.context = prev;
return this;
} has no method 'find'
at Browser.locate (/home/main/projects/node_modules/tobi/lib/browser.js:421:28)
at Browser.click (/home/main/projects/node_modules/tobi/lib/browser.js:454:27)
at /home/main/projects/tobitest.js:13:11
at IncomingMessage. (/home/main/projects/node_modules/tobi/lib/browser.js:281:9)
at IncomingMessage.emit (events.js:81:20)
at HTTPParser.onMessageComplete (http.js:133:23)
at Socket.onend (http.js:1266:12)
at Socket._onReadable (net.js:659:26)
at IOWatcher.onReadable as callback
I tried installing all dependancies and still no luck.. Any suggestions? (node version: v.0.4.10)
/**
var tobi = require('tobi') , should = require('should') , browser = tobi.createBrowser(80, 'www.google.com');
browser.get('/', function(res){ res.should.have.status(200);
browser.click("input[name=btnG]", function(res, $){ $('title').should.have.text('Google'); });
});
results in
/home/main/projects/node_modules/tobi/lib/browser.js:421 var elems = this.context.find(selector).filter(function(){ ^ TypeError: Object function (selector, fn){ var prev = this.context; this.context = this.context.find(selector); fn(); this.context = prev; return this; } has no method 'find' at Browser.locate (/home/main/projects/node_modules/tobi/lib/browser.js:421:28) at Browser.click (/home/main/projects/node_modules/tobi/lib/browser.js:454:27) at /home/main/projects/tobitest.js:13:11 at IncomingMessage. (/home/main/projects/node_modules/tobi/lib/browser.js:281:9)
at IncomingMessage.emit (events.js:81:20)
at HTTPParser.onMessageComplete (http.js:133:23)
at Socket.onend (http.js:1266:12)
at Socket._onReadable (net.js:659:26)
at IOWatcher.onReadable as callback
I tried installing all dependancies and still no luck.. Any suggestions? (node version: v.0.4.10)