Skip to content

Instantly share code, notes, and snippets.

@dalmaer
Created April 10, 2011 07:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dalmaer/912122 to your computer and use it in GitHub Desktop.
Save dalmaer/912122 to your computer and use it in GitHub Desktop.
var zombie = require("zombie");
var assert = require("assert");
// Load the page from localhost
zombie.visit("http://localhost:3000/", function (err, browser, status) {
// Fill email, password and submit form
browser.
fill("email", "zombie@underworld.dead").
fill("password", "eat-the-living").
pressButton("Sign Me Up!", function(err, browser, status) {
// Form submitted, new page loaded.
assert.equal(browser.text("title"), "Welcome To Brains Depot");
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment