https://github.com/rootslab/dado
Dado, a simple and dirty test runner.
https://github.com/rootslab/dado
test test-runner
Last synced: 10 months ago
JSON representation
Dado, a simple and dirty test runner.
- Host: GitHub
- URL: https://github.com/rootslab/dado
- Owner: rootslab
- License: mit
- Created: 2014-12-04T17:38:58.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2018-02-10T14:40:38.000Z (over 8 years ago)
- Last Synced: 2025-07-09T07:59:33.207Z (11 months ago)
- Topics: test, test-runner
- Language: JavaScript
- Size: 15.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
- License: LICENSE
Awesome Lists containing this project
README
### Dado
[](https://www.npmjs.org/package/dado)
[](https://www.codacy.com/public/44gatti/dado)
[](https://codeclimate.com/github/rootslab/dado)
[](https://github.com/rootslab/dado#mit-license)

[](http://travis-ci.org/rootslab/dado)
[](https://david-dm.org/rootslab/dado)
[](https://david-dm.org/rootslab/dado#info=devDependencies)
[](http://npm-stat.com/charts.html?package=dado)

[](https://nodei.co/npm/dado/)
> __Dado__, a simple and dirty test runner.
### Install
```bash
$ npm install dado [-g]
```
> __require__:
```javascript
var Dado = require( 'dado' );
```
### Run Tests
```bash
$ cd dado/
$ npm test
```
### Constructor
```javascript
Dado( [ Object opt ] )
// or
new Dado( [ Object opt ] )
```
#### Options
> Default options are listed.
```javascript
opt = {
}
```
### Properties
```javascript
/*
* Instance configuration object.
*/
Dado.options : Object
```
### Methods
> Arguments within [ ] are optional.
```javascript
/*
* Run tests from specified directory, default value for path is 'test' (or './test').
* Optionally, if Dado default position is not in 'node_modules', you can specify the
* relative path from 'dado/lib' directory to the root dir of the module to test
* (default relative path is * '../../../').
* The optional callback will be executed when all test files are executed, this function
* gets 2 args/objs: queues for collected files and stats.
*
* NOTE:
* - Only files ending with '-test.js' are loaded from the specified path/dir.
* - Every loaded file should exports a 'test' property/method that gets 2 arguments,
* an object with some methods for assertions and a done function that you should call
* for properly exiting from the test.
*/
Dado#do : function ( String test_dir_path [, String module_relative_path [, Function callback ] ] ) : undefined
/*
* Reset global queues and stats objects.
*/
Dado#reset : function () : Dado
```
### MIT License
> Copyright (c) 2014-present < Guglielmo Ferri : 44gatti@gmail.com >
> Permission is hereby granted, free of charge, to any person obtaining
> a copy of this software and associated documentation files (the
> 'Software'), to deal in the Software without restriction, including
> without limitation the rights to use, copy, modify, merge, publish,
> distribute, sublicense, and/or sell copies of the Software, and to
> permit persons to whom the Software is furnished to do so, subject to
> the following conditions:
> __The above copyright notice and this permission notice shall be
> included in all copies or substantial portions of the Software.__
> THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
> EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
> MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
> IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
> CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
> TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
> SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.