Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thescientist13/pipeline-test-node
A Gulp pipeline for unit testing NodeJS packages
https://github.com/thescientist13/pipeline-test-node
Last synced: 6 days ago
JSON representation
A Gulp pipeline for unit testing NodeJS packages
- Host: GitHub
- URL: https://github.com/thescientist13/pipeline-test-node
- Owner: thescientist13
- License: apache-2.0
- Created: 2015-10-20T04:20:18.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2015-10-21T00:03:45.000Z (about 9 years ago)
- Last Synced: 2024-11-09T06:40:57.057Z (2 months ago)
- Language: JavaScript
- Size: 106 KB
- Stars: 0
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
## pipeline-test-node
## Information
| Package | Description | Version|
| ------------- |:-------------:| -----:|
| pipeline-test-node| Pipeline to run tests locally using mocha | 0.1.0 |# Overview
Gulp Pipeline that generates an object which has a method to run unit tests locally using `mocha`.
_repo_: `ssh://[email protected]:kenzanmedia/pipeline-test-node.git`
_jenkins_: `https://kenzan.ci.cloudbees.com/job/CI-pipelines-test-node/`
## Install
`npm install git+ssh://[email protected]/kenzanmedia/pipeline-test-node.git`## Usage
```javascript
var gulp = require('gulp');
var testPipeline = require('pipeline-test-node')();gulp.task('default', function() {
return gulp
.src(['src/**/*.spec.js'])
.pipe(testPipeline.test());
});
```## Options
Pipeline options:
* _config_ -> Object that contains the configuration.+ __config.mochaConfig:__ Array to define mocha configurations. You can find the properties in [Mocha options](http://mochajs.org/#usage)
Default:
```javascript
config = {
mochaConfig: {
reporter: 'List',
}
}
```## Results
This pipeline returns an object. This object receives a stream with the files to test, and you can call the _test_ method to run the unit tests. It uses mocha, and validates based on the configuration provided in _config.mochaConfig_. If no configuration is provided it will use mocha's default.
## LICENSE
Copyright 2015 KenzanLicensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.