Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

eventemitter-ex

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eventemitter-ex - npm Package Compare versions

Comparing version 0.0.6 to 0.0.7

7

EventEmitterEx.js

@@ -50,2 +50,9 @@ (function () {

EventEmitterEx.prototype.startPipeline = function startPipeline (/* arguments */) {
var args = Array.prototype.slice.call(arguments);
args.unshift('end');
return this.emitAsync.apply(this, args);
};
EventEmitterEx.prototype.pipeExcept = function pipeExcept (ee) {

@@ -52,0 +59,0 @@ var self = this,

11

package.json
{
"name": "eventemitter-ex",
"version": "0.0.6",
"version": "0.0.7",
"description": "EventEmitter extensions",

@@ -8,3 +8,4 @@ "main": "EventEmitterEx.js",

"spec": "mocha test",
"test": "jshint --exclude-path=.gitignore . && mocha test"
"test": "jshint --exclude-path=.gitignore . && mocha test",
"coveralls": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | coveralls && rm -rf ./coverage"
},

@@ -26,3 +27,5 @@ "repository": {

"pipe",
"extensions"
"extensions",
"map",
"flatMap"
],

@@ -33,2 +36,4 @@ "author": "Mikhail Mazurskiy <mikhail.mazursky@gmail.com> (ash2k.com)",

"chai": "2.x.x",
"coveralls": "^2.x.x",
"istanbul": "^0.x.x",
"jshint": "2.x.x",

@@ -35,0 +40,0 @@ "mocha": "2.x.x",

@@ -6,1 +6,3 @@ # eventemitter-ex

[![Build Status](https://travis-ci.org/ash2k/eventemitter-ex.svg?branch=master)](https://travis-ci.org/ash2k/eventemitter-ex)
[![npm version](https://badge.fury.io/js/eventemitter-ex.svg)](https://badge.fury.io/js/eventemitter-ex)
[![Coverage Status](https://coveralls.io/repos/ash2k/eventemitter-ex/badge.svg?branch=master)](https://coveralls.io/r/ash2k/eventemitter-ex?branch=master)

@@ -61,4 +61,35 @@ (function () {

describe('#startPipeline()', function () {
it('should call emitAsync() with "end" event type', function () {
var A = 42, B = 17, mockEmitter = sinon.mock(emitter);
mockEmitter
.expects('emitAsync')
.withExactArgs('end', A, B);
emitter.startPipeline(A, B);
});
it('should return self', function () {
var mockEmitter = sinon.mock(emitter);
mockEmitter
.expects('emitAsync')
.withExactArgs('end')
.returnsThis();
emitter.startPipeline().should.be.equal(emitter);
});
});
describe('#pipeExcept()', function () {
it('should throw on invalid argument', function () {
expect(function () {
emitter.pipeExcept({});
}).to.throw(TypeError, /Expecting EventEmitter or EventEmitterEx/);
});
var i = 0;

@@ -65,0 +96,0 @@ [EventEmitter, EEX].forEach(function (SourceType) {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc