DalekJs (Automated cross browser testing with JavaScript!)

No comments
Short Description

DalekJS is an open source UI testing tool written in JavaScript, it will:
  • launch & automate your browser
  • fill & submit forms
  • click & follow links
  • capture screenshots
  • run your functional tests
  • … and it works on Windows, Linux & Mac.


Does DalekJS depend on Selenium?

Short answer: No. Dalek uses the Webdriver specifications, the JSON-Wire protocol to communicate with the browsers it utilitizes, when applicaple. The Webdriver specification evolved out of the Selenium project & then got submitted as a draft to the W3C. So, in some ways, Daleks existance would not be possible without the work the Selenium project has done so far. But Daleks only dependency is Node, no need to install Java or download the Selenium.jar file.
Installation
Dalek's installation is pretty forward, just make sure you have Node.js installed. If you don't have Node installed, just go to nodejs.org & follow the instructions of the graphical installer.

With node comes a handy package management tool called `npm`. You can verify, if the installation succeeded when you open your command line & type
$ npm --version
then you should see some output like this
$ 1.1.62
where the version number depends on your installed version of Node.
If that worked, you should be able to install DalekJS.
Dalek is split up in a few different parts, to get it working initially, you first have to install the "Dalek Command Line Tools", this is as easy as typing
$ npm install dalek-cli -g
in your command line.
Verify that the installation worked by checking with
$ dalek -v
You should see something like this
$ DalekJS CLI Tools Version: 0.0.1
  Brought to you with love by: Sebastian Golasch (@asciidisco) 2013
Awesome, you're one step closer to the finish line, next up, you need to add a package.json file to your projects root directory, if you haven't one already. You can start with the bare minimum of that file, which should look something like this:
  "name": "myCssTardis",
  "description": "Is awesome",
  "version": "0.0.2"
}
Hah, you "nodyfied" project & I guess, now that you learned to love the command line, you would really like to go back & hack!? Great, then the next step is something for you, we install the Dalek base framework & all its dependencies with a one liner that looks like this:
$ npm install dalekjs --save-dev
Guess what?! That was it. You installed DalekJS you old command line hero, if you want to verify, that the local installation worked, you can, again, ask Dalek in which version it is running, because now, it will also tell you the version number of your local Dalek installation:
$ dalek -v
You should see something like this
$ DalekJS CLI Tools Version: 0.0.1
  DalekJS local install: 0.0.1
  Brought to you with love by: Sebastian Golasch (@asciidisco) 2013

No comments :

Post a Comment