formidable
Advanced tools
Comparing version 1.0.1 to 1.0.2
require('../test/common'); | ||
var multipartParser = require('formidable/multipart_parser'), | ||
var multipartParser = require('../lib/multipart_parser'), | ||
MultipartParser = multipartParser.MultipartParser, | ||
@@ -49,3 +49,3 @@ parser = new MultipartParser(), | ||
p(mbPerSec+' mb/sec'); | ||
console.log(mbPerSec+' mb/sec'); | ||
@@ -52,0 +52,0 @@ assert.equal(nparsed, buffer.length); |
@@ -72,2 +72,5 @@ if (global.GENTLY) require = GENTLY.hijack(require); | ||
}) | ||
.on('aborted', function() { | ||
self.emit('aborted'); | ||
}) | ||
.on('data', function(buffer) { | ||
@@ -74,0 +77,0 @@ self.write(buffer); |
{ | ||
"name": "formidable", | ||
"version": "1.0.1", | ||
"dependencies": { | ||
"version": "1.0.2", | ||
"dependencies": {}, | ||
"devDependencies": { | ||
"gently": ">=0.7.0" | ||
@@ -13,4 +14,3 @@ }, | ||
"node": "*" | ||
}, | ||
"devDependencies": {} | ||
} | ||
} |
@@ -23,2 +23,11 @@ # Formidable | ||
### v1.0.2 | ||
* Exclude node\_modules folder from git | ||
* Implement new `'aborted'` event | ||
* Fix files in example folder to work with recent node versions | ||
* Make gently a devDependency | ||
[See Commits](https://github.com/felixge/node-formidable/compare/v1.0.1...v1.0.2) | ||
### v1.0.1 | ||
@@ -208,2 +217,6 @@ | ||
#### Event: 'aborted' | ||
Emitted when the request was aborted by the user. Right now this can be due to a 'timeout' or 'close' event on the socket. In the future there will be a seperate 'timeout' event (needs a change in the node core). | ||
#### Event: 'end' () | ||
@@ -210,0 +223,0 @@ |
@@ -63,3 +63,3 @@ var common = require('../common'); | ||
var events = ['error', 'data', 'end']; | ||
var events = ['error', 'aborted', 'data', 'end']; | ||
gently.expect(REQ, 'on', events.length, function(event, fn) { | ||
@@ -143,2 +143,11 @@ assert.equal(event, events.shift()); | ||
(function testEmitAborted() { | ||
gently.expect(form, 'emit',function(event) { | ||
assert.equal(event, 'aborted'); | ||
}); | ||
emit.aborted(); | ||
})(); | ||
(function testEmitData() { | ||
@@ -186,3 +195,3 @@ var BUFFER = [1, 2, 3]; | ||
gently.expect(form, 'writeHeaders'); | ||
gently.expect(REQ, 'on', 3, function() { | ||
gently.expect(REQ, 'on', 4, function() { | ||
return this; | ||
@@ -216,3 +225,3 @@ }); | ||
gently.expect(form, 'writeHeaders'); | ||
gently.expect(REQ, 'on', 3, function() { | ||
gently.expect(REQ, 'on', 4, function() { | ||
return this; | ||
@@ -219,0 +228,0 @@ }); |
Sorry, the diff of this file is not supported yet
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
0
1727
259
3
62152
1
24
- Removedgently@>=0.7.0
- Removedgently@1.0.0(transitive)