shinout/browser — Issue #1: jsdom window won't be created
Author: oschrenk
Created: 2011-11-02 16:31:37+00:00
State: open

I have problems running the the login sample2. It seems that the jsdom window object won't be created.

```
[...]
$b.browse(function(err, out) {
console.log ("creating jsdom window");
var window = jsdom(out.result).createWindow();
console.log ("created jsdom window");
var $ = jquery.create(window);
var postdata = {
Email : userdata.email,
Passwd : userdata.pass
};
var url = $("#gaia_loginform").attr("action");
// get hidden fields, and register them to post data
$("input").each(function(k, el) {
var $el = $(el);
var name = $el.attr("name"), type = $el.attr("type"), val = $el.val();
if (type == "hidden" || type == "submit") postdata[name] = val;
});
return [url, {
data : postdata, // set post data
method: "POST" // set HTTP method (default: GET)
}];
})
.after("login"); // browse after browsing with label="login"
[...]
```

I added some log statements and never get "created jsdom window" back.

Maybe jsdom changed the API? `npm install browser` installs jsdom 0.2.9 for me.