Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't get Google example to work #60

Open
j5bart opened this issue Aug 3, 2011 · 2 comments
Open

Can't get Google example to work #60

j5bart opened this issue Aug 3, 2011 · 2 comments

Comments

@j5bart
Copy link

j5bart commented Aug 3, 2011

/**

  • Module dependencies.
    */

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)

@Almad
Copy link

Almad commented Feb 8, 2012

Same here.

@richzw
Copy link

richzw commented Jul 22, 2012

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants