https://github.com/dylanfoster/nightwing
UI automated test framework using webdriverjs and mocha
https://github.com/dylanfoster/nightwing
Last synced: about 2 months ago
JSON representation
UI automated test framework using webdriverjs and mocha
- Host: GitHub
- URL: https://github.com/dylanfoster/nightwing
- Owner: dylanfoster
- License: mit
- Created: 2015-06-11T04:14:44.000Z (about 11 years ago)
- Default Branch: development
- Last Pushed: 2015-07-05T04:23:36.000Z (almost 11 years ago)
- Last Synced: 2025-11-27T09:22:08.652Z (7 months ago)
- Language: JavaScript
- Size: 188 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# nightwing [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url]
An intuitive interaction library based on [webdriverjs](https://www.npmjs.com/package/selenium-webdriver)
## Install
```sh
$ npm install --save nightwing
```
## Usage
nightwing works by injecting several intuitive commands globally into your tests.
By default, [mochajs](http://mochajs.org) is used as the test runner, but this can be
configured using the `--runner` flag or programmatically by passing in `{ runner: foo }`
to the `Nightwing` constructor. **Note** currently, only Mocha is supported, but
we plan to continue building out support for more runners in the future
myFirstTest.js
```javascript
describe("foo", function () {
before(function () {
return browser.get("http://www.apple.com");
});
it("bar", function () {
fillIn("input[name=q]", "foobar")
click(".submit");
expect(title()).to.eql("foobar - Google Search");
});
});
```
## Programmatic Interface
runner.js
```javascript
var Nightwing = require("nightwing");
var nightwing = new Nightwing(options);
nightwing.addFile("/path/to/file.js")
nightwing.run(function (results) {
});
```
**options**
Since nightwing injects itself into to the test runner, all options available to the test runner are availble to nigthwing.
- [mochajs#options](https://github.com/mochajs/mocha/wiki/Using-mocha-programmatically)
## Command-line
```sh
$ nightwing [options] [files|dir]
```
## Commands api
// TODO
## License
MIT © Dylan Foster
[npm-image]: https://badge.fury.io/js/nightwing.svg
[npm-url]: https://npmjs.org/package/nightwing
[travis-image]: https://travis-ci.org/dylanfoster/nightwing.svg?branch=development
[travis-url]: https://travis-ci.org/dylanfoster/nightwing
[daviddm-image]: https://david-dm.org/dylanfoster/nightwing.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/dylanfoster/nightwing