fsevents 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fsevents might be problematic. Click here for more details.
- package/node_modules/node-pre-gyp/CHANGELOG.md +9 -0
- package/node_modules/node-pre-gyp/lib/util/abi_crosswalk.json +32 -0
- package/node_modules/node-pre-gyp/node_modules/mkdirp/node_modules/minimist/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/nopt/README.md +8 -7
- package/node_modules/node-pre-gyp/node_modules/nopt/package.json +16 -12
- package/node_modules/node-pre-gyp/node_modules/npmlog/node_modules/are-we-there-yet/node_modules/readable-stream/node_modules/core-util-is/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/npmlog/node_modules/are-we-there-yet/node_modules/readable-stream/node_modules/inherits/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/npmlog/node_modules/are-we-there-yet/node_modules/readable-stream/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/rc/lib/utils.js +2 -2
- package/node_modules/node-pre-gyp/node_modules/rc/node_modules/minimist/index.js +14 -2
- package/node_modules/node-pre-gyp/node_modules/rc/node_modules/minimist/package.json +10 -9
- package/node_modules/node-pre-gyp/node_modules/rc/node_modules/minimist/test/bool.js +23 -0
- package/node_modules/node-pre-gyp/node_modules/rc/node_modules/minimist/test/kv_short.js +16 -0
- package/node_modules/node-pre-gyp/node_modules/rc/package.json +9 -8
- package/node_modules/node-pre-gyp/node_modules/request/.travis.yml +1 -0
- package/node_modules/node-pre-gyp/node_modules/request/CHANGELOG.md +22 -2
- package/node_modules/node-pre-gyp/node_modules/request/README.md +42 -10
- package/node_modules/node-pre-gyp/node_modules/request/index.js +4 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/aws-sign2/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/inherits/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/index.js +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/{form-data/node_modules/async/LICENSE → bl/node_modules/readable-stream/node_modules/process-nextick-args/license.md} +6 -6
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/package.json +10 -9
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/test.js +7 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/bl/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/caseless/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/extend/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/forever-agent/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/Readme.md +44 -9
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/lib/form_data.js +48 -25
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/lib/async.js +13 -7
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/package.json +26 -11
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/package.json +29 -20
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/README.md +4 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/browser/bluebird.js +35 -11
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/browser/bluebird.min.js +5 -5
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/debuggability.js +2 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/direct_resolve.js +2 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/promise.js +5 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/promisify.js +10 -5
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/using.js +14 -3
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/bluebird/package.json +9 -8
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/chalk/index.js +2 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/chalk/node_modules/escape-string-regexp/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/chalk/package.json +22 -15
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/chalk/readme.md +3 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/commander/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/README.md +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/generate-function/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/generate-object-property/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/.travis.yml +6 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/README.md +3 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/jsonpointer.js +7 -10
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/package.json +24 -20
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/test.js +11 -13
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/package.json +11 -10
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/boom/.travis.yml +3 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/boom/lib/index.js +39 -28
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/boom/package.json +11 -12
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/boom/test/index.js +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/.npmignore +18 -18
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/.travis.yml +8 -5
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/README.md +2 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json +24 -28
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/test/index.js +57 -63
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/.travis.yml +2 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/LICENSE +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/README.md +16 -6
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/images/hoek.png +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/lib/escape.js +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/lib/index.js +24 -8
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/package.json +13 -13
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/test/escaper.js +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/test/index.js +866 -778
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/test/modules/test1.js +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/test/modules/test2.js +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/test/modules/test3.js +0 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/sntp/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/isstream/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/HISTORY.md +24 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/index.js +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/node_modules/mime-db/HISTORY.md +33 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/node_modules/mime-db/db.json +50 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/node_modules/mime-db/package.json +12 -13
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/mime-types/package.json +9 -10
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/node-uuid/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/.npmignore +0 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/.travis.yml +3 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/CHANGELOG.md +13 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/README.md +11 -4
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/bower.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/component.json +15 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/dist/qs.js +523 -0
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/lib/parse.js +3 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/lib/stringify.js +28 -7
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/package.json +20 -18
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/test/parse.js +14 -14
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/qs/test/stringify.js +23 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/stringstream/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/request/package.json +12 -12
- package/node_modules/node-pre-gyp/node_modules/request/request.js +51 -30
- package/node_modules/node-pre-gyp/node_modules/rimraf/node_modules/glob/node_modules/inherits/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/rimraf/node_modules/glob/node_modules/minimatch/package.json +3 -2
- package/node_modules/node-pre-gyp/node_modules/rimraf/node_modules/glob/package.json +2 -1
- package/node_modules/node-pre-gyp/node_modules/rimraf/package.json +9 -8
- package/node_modules/node-pre-gyp/node_modules/rimraf/rimraf.js +1 -1
- package/node_modules/node-pre-gyp/node_modules/semver/package.json +10 -12
- package/node_modules/node-pre-gyp/node_modules/semver/semver.js +1 -0
- package/node_modules/node-pre-gyp/node_modules/semver/test/index.js +21 -8
- package/node_modules/node-pre-gyp/node_modules/tar/lib/entry.js +7 -0
- package/node_modules/node-pre-gyp/node_modules/tar/lib/parse.js +5 -1
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/fs.js +21 -11
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/graceful-fs.js +208 -115
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/legacy-streams.js +118 -0
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/package.json +18 -17
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/polyfills.js +130 -133
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/package.json +18 -14
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/inherits/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/tar/package.json +22 -15
- package/node_modules/node-pre-gyp/node_modules/tar/test/parse-discard.js +29 -0
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/inherits/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/minimatch/node_modules/lru-cache/README.md +12 -2
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js +48 -4
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/minimatch/node_modules/lru-cache/package.json +9 -9
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/minimatch/node_modules/lru-cache/test/basic.js +26 -25
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/fstream-ignore/node_modules/minimatch/node_modules/lru-cache/test/serialize.js +216 -0
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/readable-stream/node_modules/core-util-is/package.json +1 -1
- package/node_modules/node-pre-gyp/node_modules/tar-pack/node_modules/readable-stream/package.json +1 -1
- package/node_modules/node-pre-gyp/package.json +10 -10
- package/package.json +2 -2
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/.jscsrc +0 -3
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/CHANGELOG.md +0 -81
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/README.md +0 -1789
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/form-data/node_modules/async/support/sync-package-managers.js +0 -53
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/Makefile +0 -9
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/cryptiles/index.js +0 -1
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/Makefile +0 -8
- package/node_modules/node-pre-gyp/node_modules/request/node_modules/hawk/node_modules/hoek/index.js +0 -1
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/.npmignore +0 -1
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/LICENSE +0 -15
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/test/max-open.js +0 -69
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/test/open.js +0 -39
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/test/readdir-sort.js +0 -20
- package/node_modules/node-pre-gyp/node_modules/tar/node_modules/fstream/node_modules/graceful-fs/test/write-then-read.js +0 -47
@@ -93,31 +93,6 @@ test("reset", function (t) {
|
|
93
93
|
})
|
94
94
|
|
95
95
|
|
96
|
-
// Note: `<cache>.dump()` is a debugging tool only. No guarantees are made
|
97
|
-
// about the format/layout of the response.
|
98
|
-
test("dump", function (t) {
|
99
|
-
var cache = new LRU(10)
|
100
|
-
var d = cache.dump();
|
101
|
-
t.equal(Object.keys(d).length, 0, "nothing in dump for empty cache")
|
102
|
-
cache.set("a", "A")
|
103
|
-
var d = cache.dump() // { a: { key: "a", value: "A", lu: 0 } }
|
104
|
-
t.ok(d.a)
|
105
|
-
t.equal(d.a.key, "a")
|
106
|
-
t.equal(d.a.value, "A")
|
107
|
-
t.equal(d.a.lu, 0)
|
108
|
-
|
109
|
-
cache.set("b", "B")
|
110
|
-
cache.get("b")
|
111
|
-
d = cache.dump()
|
112
|
-
t.ok(d.b)
|
113
|
-
t.equal(d.b.key, "b")
|
114
|
-
t.equal(d.b.value, "B")
|
115
|
-
t.equal(d.b.lu, 2)
|
116
|
-
|
117
|
-
t.end()
|
118
|
-
})
|
119
|
-
|
120
|
-
|
121
96
|
test("basic with weighed length", function (t) {
|
122
97
|
var cache = new LRU({
|
123
98
|
max: 100,
|
@@ -182,6 +157,32 @@ test("lru recently gotten with weighed length", function (t) {
|
|
182
157
|
t.end()
|
183
158
|
})
|
184
159
|
|
160
|
+
test("lru recently updated with weighed length", function (t) {
|
161
|
+
var cache = new LRU({
|
162
|
+
max: 8,
|
163
|
+
length: function (item) { return item.length }
|
164
|
+
})
|
165
|
+
cache.set("a", "A")
|
166
|
+
cache.set("b", "BB")
|
167
|
+
cache.set("c", "CCC")
|
168
|
+
t.equal(cache.length, 6) //CCC BB A
|
169
|
+
cache.set("a", "+A")
|
170
|
+
t.equal(cache.length, 7) //+A CCC BB
|
171
|
+
cache.set("b", "++BB")
|
172
|
+
t.equal(cache.length, 6) //++BB +A
|
173
|
+
t.equal(cache.get("c"), undefined)
|
174
|
+
|
175
|
+
cache.set("c", "oversized")
|
176
|
+
t.equal(cache.length, 6) //++BB +A
|
177
|
+
t.equal(cache.get("c"), undefined)
|
178
|
+
|
179
|
+
cache.set("a", "oversized")
|
180
|
+
t.equal(cache.length, 4) //++BB
|
181
|
+
t.equal(cache.get("a"), undefined)
|
182
|
+
t.equal(cache.get("b"), "++BB")
|
183
|
+
t.end()
|
184
|
+
})
|
185
|
+
|
185
186
|
test("set returns proper booleans", function(t) {
|
186
187
|
var cache = new LRU({
|
187
188
|
max: 5,
|
@@ -0,0 +1,216 @@
|
|
1
|
+
var test = require('tap').test
|
2
|
+
var LRU = require('../')
|
3
|
+
|
4
|
+
test('dump', function (t) {
|
5
|
+
var cache = new LRU()
|
6
|
+
|
7
|
+
t.equal(cache.dump().length, 0, "nothing in dump for empty cache")
|
8
|
+
|
9
|
+
cache.set("a", "A")
|
10
|
+
cache.set("b", "B")
|
11
|
+
t.deepEqual(cache.dump(), [
|
12
|
+
{ k: "b", v: "B", e: 0 },
|
13
|
+
{ k: "a", v: "A", e: 0 }
|
14
|
+
])
|
15
|
+
|
16
|
+
cache.set("a", "A");
|
17
|
+
t.deepEqual(cache.dump(), [
|
18
|
+
{ k: "a", v: "A", e: 0 },
|
19
|
+
{ k: "b", v: "B", e: 0 }
|
20
|
+
])
|
21
|
+
|
22
|
+
cache.get("b");
|
23
|
+
t.deepEqual(cache.dump(), [
|
24
|
+
{ k: "b", v: "B", e: 0 },
|
25
|
+
{ k: "a", v: "A", e: 0 }
|
26
|
+
])
|
27
|
+
|
28
|
+
cache.del("a");
|
29
|
+
t.deepEqual(cache.dump(), [
|
30
|
+
{ k: "b", v: "B", e: 0 }
|
31
|
+
])
|
32
|
+
|
33
|
+
t.end()
|
34
|
+
})
|
35
|
+
|
36
|
+
test("do not dump stale items", function(t) {
|
37
|
+
var cache = new LRU({
|
38
|
+
max: 5,
|
39
|
+
maxAge: 50
|
40
|
+
})
|
41
|
+
|
42
|
+
//expires at 50
|
43
|
+
cache.set("a", "A")
|
44
|
+
|
45
|
+
setTimeout(function () {
|
46
|
+
//expires at 75
|
47
|
+
cache.set("b", "B")
|
48
|
+
var s = cache.dump()
|
49
|
+
t.equal(s.length, 2)
|
50
|
+
t.equal(s[0].k, "b")
|
51
|
+
t.equal(s[1].k, "a")
|
52
|
+
}, 25)
|
53
|
+
|
54
|
+
setTimeout(function () {
|
55
|
+
//expires at 110
|
56
|
+
cache.set("c", "C")
|
57
|
+
var s = cache.dump()
|
58
|
+
t.equal(s.length, 2)
|
59
|
+
t.equal(s[0].k, "c")
|
60
|
+
t.equal(s[1].k, "b")
|
61
|
+
}, 60)
|
62
|
+
|
63
|
+
setTimeout(function () {
|
64
|
+
//expires at 130
|
65
|
+
cache.set("d", "D", 40)
|
66
|
+
var s = cache.dump()
|
67
|
+
t.equal(s.length, 2)
|
68
|
+
t.equal(s[0].k, "d")
|
69
|
+
t.equal(s[1].k, "c")
|
70
|
+
}, 90)
|
71
|
+
|
72
|
+
setTimeout(function () {
|
73
|
+
var s = cache.dump()
|
74
|
+
t.equal(s.length, 1)
|
75
|
+
t.equal(s[0].k, "d")
|
76
|
+
}, 120)
|
77
|
+
|
78
|
+
setTimeout(function () {
|
79
|
+
var s = cache.dump()
|
80
|
+
t.deepEqual(s, [])
|
81
|
+
t.end()
|
82
|
+
}, 155)
|
83
|
+
})
|
84
|
+
|
85
|
+
test("load basic cache", function(t) {
|
86
|
+
var cache = new LRU(),
|
87
|
+
copy = new LRU()
|
88
|
+
|
89
|
+
cache.set("a", "A")
|
90
|
+
cache.set("b", "B")
|
91
|
+
|
92
|
+
copy.load(cache.dump())
|
93
|
+
t.deepEquals(cache.dump(), copy.dump())
|
94
|
+
|
95
|
+
t.end()
|
96
|
+
})
|
97
|
+
|
98
|
+
|
99
|
+
test("load staled cache", function(t) {
|
100
|
+
var cache = new LRU({maxAge: 50}),
|
101
|
+
copy = new LRU({maxAge: 50}),
|
102
|
+
arr
|
103
|
+
|
104
|
+
//expires at 50
|
105
|
+
cache.set("a", "A")
|
106
|
+
setTimeout(function () {
|
107
|
+
//expires at 80
|
108
|
+
cache.set("b", "B")
|
109
|
+
arr = cache.dump()
|
110
|
+
t.equal(arr.length, 2)
|
111
|
+
}, 30)
|
112
|
+
|
113
|
+
setTimeout(function () {
|
114
|
+
copy.load(arr)
|
115
|
+
t.equal(copy.get("a"), undefined)
|
116
|
+
t.equal(copy.get("b"), "B")
|
117
|
+
}, 60)
|
118
|
+
|
119
|
+
setTimeout(function () {
|
120
|
+
t.equal(copy.get("b"), undefined)
|
121
|
+
t.end()
|
122
|
+
}, 90)
|
123
|
+
})
|
124
|
+
|
125
|
+
test("load to other size cache", function(t) {
|
126
|
+
var cache = new LRU({max: 2}),
|
127
|
+
copy = new LRU({max: 1})
|
128
|
+
|
129
|
+
cache.set("a", "A")
|
130
|
+
cache.set("b", "B")
|
131
|
+
|
132
|
+
copy.load(cache.dump())
|
133
|
+
t.equal(copy.get("a"), undefined)
|
134
|
+
t.equal(copy.get("b"), "B")
|
135
|
+
|
136
|
+
//update the last read from original cache
|
137
|
+
cache.get("a")
|
138
|
+
copy.load(cache.dump())
|
139
|
+
t.equal(copy.get("a"), "A")
|
140
|
+
t.equal(copy.get("b"), undefined)
|
141
|
+
|
142
|
+
t.end()
|
143
|
+
})
|
144
|
+
|
145
|
+
|
146
|
+
test("load to other age cache", function(t) {
|
147
|
+
var cache = new LRU({maxAge: 50}),
|
148
|
+
aged = new LRU({maxAge: 100}),
|
149
|
+
simple = new LRU(),
|
150
|
+
arr,
|
151
|
+
expired
|
152
|
+
|
153
|
+
//created at 0
|
154
|
+
//a would be valid till 0 + 50
|
155
|
+
cache.set("a", "A")
|
156
|
+
setTimeout(function () {
|
157
|
+
//created at 20
|
158
|
+
//b would be valid till 20 + 50
|
159
|
+
cache.set("b", "B")
|
160
|
+
//b would be valid till 20 + 70
|
161
|
+
cache.set("c", "C", 70)
|
162
|
+
arr = cache.dump()
|
163
|
+
t.equal(arr.length, 3)
|
164
|
+
}, 20)
|
165
|
+
|
166
|
+
setTimeout(function () {
|
167
|
+
t.equal(cache.get("a"), undefined)
|
168
|
+
t.equal(cache.get("b"), "B")
|
169
|
+
t.equal(cache.get("c"), "C")
|
170
|
+
|
171
|
+
aged.load(arr)
|
172
|
+
t.equal(aged.get("a"), undefined)
|
173
|
+
t.equal(aged.get("b"), "B")
|
174
|
+
t.equal(aged.get("c"), "C")
|
175
|
+
|
176
|
+
simple.load(arr)
|
177
|
+
t.equal(simple.get("a"), undefined)
|
178
|
+
t.equal(simple.get("b"), "B")
|
179
|
+
t.equal(simple.get("c"), "C")
|
180
|
+
}, 60)
|
181
|
+
|
182
|
+
setTimeout(function () {
|
183
|
+
t.equal(cache.get("a"), undefined)
|
184
|
+
t.equal(cache.get("b"), undefined)
|
185
|
+
t.equal(cache.get("c"), "C")
|
186
|
+
|
187
|
+
aged.load(arr)
|
188
|
+
t.equal(aged.get("a"), undefined)
|
189
|
+
t.equal(aged.get("b"), undefined)
|
190
|
+
t.equal(aged.get("c"), "C")
|
191
|
+
|
192
|
+
simple.load(arr)
|
193
|
+
t.equal(simple.get("a"), undefined)
|
194
|
+
t.equal(simple.get("b"), undefined)
|
195
|
+
t.equal(simple.get("c"), "C")
|
196
|
+
}, 80)
|
197
|
+
|
198
|
+
setTimeout(function () {
|
199
|
+
t.equal(cache.get("a"), undefined)
|
200
|
+
t.equal(cache.get("b"), undefined)
|
201
|
+
t.equal(cache.get("c"), undefined)
|
202
|
+
|
203
|
+
aged.load(arr)
|
204
|
+
t.equal(aged.get("a"), undefined)
|
205
|
+
t.equal(aged.get("b"), undefined)
|
206
|
+
t.equal(aged.get("c"), undefined)
|
207
|
+
|
208
|
+
simple.load(arr)
|
209
|
+
t.equal(simple.get("a"), undefined)
|
210
|
+
t.equal(simple.get("b"), undefined)
|
211
|
+
t.equal(simple.get("c"), undefined)
|
212
|
+
t.end()
|
213
|
+
}, 100)
|
214
|
+
|
215
|
+
})
|
216
|
+
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "node-pre-gyp",
|
3
3
|
"description": "Node.js native addon binary install tool",
|
4
|
-
"version": "0.6.
|
4
|
+
"version": "0.6.11",
|
5
5
|
"keywords": [
|
6
6
|
"native",
|
7
7
|
"addon",
|
@@ -29,7 +29,7 @@
|
|
29
29
|
"npmlog": "~1.2.0",
|
30
30
|
"request": "2.x",
|
31
31
|
"semver": "~5.0.1",
|
32
|
-
"tar": "~2.
|
32
|
+
"tar": "~2.2.0",
|
33
33
|
"tar-pack": "~2.0.0",
|
34
34
|
"mkdirp": "~0.5.0",
|
35
35
|
"rc": "~1.1.0",
|
@@ -54,11 +54,11 @@
|
|
54
54
|
"node": ">= 0.8.0"
|
55
55
|
},
|
56
56
|
"scripts": {
|
57
|
-
"prepublish": "retire -n && npm ls && jshint test
|
57
|
+
"prepublish": "retire -n && npm ls && jshint test/build.test.js test/s3_setup.test.js test/versioning.test.js",
|
58
58
|
"update-crosswalk": "node scripts/abi_crosswalk.js",
|
59
59
|
"test": "jshint lib lib/util scripts bin/node-pre-gyp && mocha -R spec --timeout 500000"
|
60
60
|
},
|
61
|
-
"gitHead": "
|
61
|
+
"gitHead": "7a6148f49e5c72823561428def35ac6d5fd80d62",
|
62
62
|
"bugs": {
|
63
63
|
"url": "https://github.com/mapbox/node-pre-gyp/issues"
|
64
64
|
},
|
@@ -74,9 +74,9 @@
|
|
74
74
|
"rc",
|
75
75
|
"rimraf"
|
76
76
|
],
|
77
|
-
"_id": "node-pre-gyp@0.6.
|
78
|
-
"_shasum": "
|
79
|
-
"_from": "node-pre-gyp
|
77
|
+
"_id": "node-pre-gyp@0.6.11",
|
78
|
+
"_shasum": "2541473fadafd124a251216b6c3be1b71ff6b46a",
|
79
|
+
"_from": "node-pre-gyp@0.6.11",
|
80
80
|
"_npmVersion": "1.4.28",
|
81
81
|
"_npmUser": {
|
82
82
|
"name": "springmeyer",
|
@@ -105,10 +105,10 @@
|
|
105
105
|
}
|
106
106
|
],
|
107
107
|
"dist": {
|
108
|
-
"shasum": "
|
109
|
-
"tarball": "http://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.
|
108
|
+
"shasum": "2541473fadafd124a251216b6c3be1b71ff6b46a",
|
109
|
+
"tarball": "http://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.11.tgz"
|
110
110
|
},
|
111
111
|
"directories": {},
|
112
|
-
"_resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.
|
112
|
+
"_resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.11.tgz",
|
113
113
|
"readme": "ERROR: No README data found!"
|
114
114
|
}
|
package/package.json
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
{
|
2
2
|
"name": "fsevents",
|
3
|
-
"version": "1.0.
|
3
|
+
"version": "1.0.1",
|
4
4
|
"description": "Native Access to Mac OS-X FSEvents",
|
5
5
|
"main": "fsevents.js",
|
6
6
|
"dependencies": {
|
7
7
|
"nan": "^2.0.2",
|
8
|
-
"node-pre-gyp": "^0.6.
|
8
|
+
"node-pre-gyp": "^0.6.11"
|
9
9
|
},
|
10
10
|
"os": [
|
11
11
|
"darwin"
|
@@ -1,81 +0,0 @@
|
|
1
|
-
# v1.3.0
|
2
|
-
|
3
|
-
New Features:
|
4
|
-
- Added `constant`
|
5
|
-
- Added `asyncify`/`wrapSync` for making sync functions work with callbacks. (#671, #806)
|
6
|
-
- Added `during` and `doDuring`, which are like `whilst` with an async truth test. (#800)
|
7
|
-
- `retry` now accepts an `interval` parameter to specify a delay between retries. (#793)
|
8
|
-
- `async` should work better in Web Workers due to better `root` detection (#804)
|
9
|
-
- Callbacks are now optional in `whilst`, `doWhilst`, `until`, and `doUntil` (#642)
|
10
|
-
- Various internal updates (#786, #801, #802, #803)
|
11
|
-
- Various doc fixes (#790, #794)
|
12
|
-
|
13
|
-
Bug Fixes:
|
14
|
-
- `cargo` now exposes the `payload` size, and `cargo.payload` can be changed on the fly after the `cargo` is created. (#740, #744, #783)
|
15
|
-
|
16
|
-
# v1.2.1
|
17
|
-
|
18
|
-
Bug Fix:
|
19
|
-
|
20
|
-
- Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782)
|
21
|
-
|
22
|
-
|
23
|
-
# v1.2.0
|
24
|
-
|
25
|
-
New Features:
|
26
|
-
|
27
|
-
- Added `timesLimit` (#743)
|
28
|
-
- `concurrency` can be changed after initialization in `queue` by setting `q.concurrency`. The new concurrency will be reflected the next time a task is processed. (#747, #772)
|
29
|
-
|
30
|
-
Bug Fixes:
|
31
|
-
|
32
|
-
- Fixed a regression in `each` and family with empty arrays that have additional properties. (#775, #777)
|
33
|
-
|
34
|
-
|
35
|
-
# v1.1.1
|
36
|
-
|
37
|
-
Bug Fix:
|
38
|
-
|
39
|
-
- Small regression with synchronous iterator behavior in `eachSeries` with a 1-element array. Before 1.1.0, `eachSeries`'s callback was called on the same tick, which this patch restores. In 2.0.0, it will be called on the next tick. (#782)
|
40
|
-
|
41
|
-
|
42
|
-
# v1.1.0
|
43
|
-
|
44
|
-
New Features:
|
45
|
-
|
46
|
-
- `cargo` now supports all of the same methods and event callbacks as `queue`.
|
47
|
-
- Added `ensureAsync` - A wrapper that ensures an async function calls its callback on a later tick. (#769)
|
48
|
-
- Optimized `map`, `eachOf`, and `waterfall` families of functions
|
49
|
-
- Passing a `null` or `undefined` array to `map`, `each`, `parallel` and families will be treated as an empty array (#667).
|
50
|
-
- The callback is now optional for the composed results of `compose` and `seq`. (#618)
|
51
|
-
- Reduced file size by 4kb, (minified version by 1kb)
|
52
|
-
- Added code coverage through `nyc` and `coveralls` (#768)
|
53
|
-
|
54
|
-
Bug Fixes:
|
55
|
-
|
56
|
-
- `forever` will no longer stack overflow with a synchronous iterator (#622)
|
57
|
-
- `eachLimit` and other limit functions will stop iterating once an error occurs (#754)
|
58
|
-
- Always pass `null` in callbacks when there is no error (#439)
|
59
|
-
- Ensure proper conditions when calling `drain()` after pushing an empty data set to a queue (#668)
|
60
|
-
- `each` and family will properly handle an empty array (#578)
|
61
|
-
- `eachSeries` and family will finish if the underlying array is modified during execution (#557)
|
62
|
-
- `queue` will throw if a non-function is passed to `q.push()` (#593)
|
63
|
-
- Doc fixes (#629, #766)
|
64
|
-
|
65
|
-
|
66
|
-
# v1.0.0
|
67
|
-
|
68
|
-
No known breaking changes, we are simply complying with semver from here on out.
|
69
|
-
|
70
|
-
Changes:
|
71
|
-
|
72
|
-
- Start using a changelog!
|
73
|
-
- Add `forEachOf` for iterating over Objects (or to iterate Arrays with indexes available) (#168 #704 #321)
|
74
|
-
- Detect deadlocks in `auto` (#663)
|
75
|
-
- Better support for require.js (#527)
|
76
|
-
- Throw if queue created with concurrency `0` (#714)
|
77
|
-
- Fix unneeded iteration in `queue.resume()` (#758)
|
78
|
-
- Guard against timer mocking overriding `setImmediate` (#609 #611)
|
79
|
-
- Miscellaneous doc fixes (#542 #596 #615 #628 #631 #690 #729)
|
80
|
-
- Use single noop function internally (#546)
|
81
|
-
- Optimize internal `_each`, `_map` and `_keys` functions.
|