Is there a capybara for Node.js? Is there a capybara for Node.js? selenium selenium

Is there a capybara for Node.js?


How about Zombie?

Zombie.js

Insanely fast, headless full-stack testing using Node.js

The Bite

If you're going to write an insanely fast, headless browser, how can you not call it Zombie Zombie it is.

Zombie.js is a lightweight framework for testing client-side JavaScript code in a simulated environment. No browser required.


I'm a rails-turned-node developer and I've always been looking for a analogy in the JS world for the winning RSpec/Capybara combination. Here is what I've found what I like best.

  • Mocha - for running asynchronous tests
  • Chai - for assertions
  • Request - for handling HTTP request/response
  • Cheerio - for selecting HTML elements from responses

Here is a more involved post on how to set up this stack including continuous test running.

Happy Testing!


Cucumber-JS is the closest you will get in Javascript:https://github.com/cucumber/cucumber-js

You can use the library to drive JS, headless and Selenium, however it is missing the 'capybara' shared API between each of the different 'worlds'. There is a good talk at http://skillsmatter.com/podcast/agile-testing/cucumber-js-cuke-up-your-javascript and supporting github code at https://github.com/jbpros/cukecipes

I'm hoping that when the phantomjs webdriver wire protocol is finished (https://github.com/detro/ghostdriver) and if Soda/Selenium (https://github.com/LearnBoost/soda) is able to drive it then the headless tests will be able to be automated via Selenium thus bypassing the need for Capybara.