Skip to content
This repository was archived by the owner on Dec 1, 2024. It is now read-only.

Commit c90b871

Browse files
dependabot[bot]vweevers
authored andcommitted
Bump tape from 4.13.3 to 5.2.1 and pin run-parallel
- Bump `tape` devDependency from 4.13.3 to 5.2.1 - Avoid `t.throws()`, fails on errors with non-configurable message - Pin `run-parallel` to 1.1.10 for browser compatibility. Later versions depend on `queue-microtask` which uses arrow functions and promises.
1 parent 3988b66 commit c90b871

3 files changed

Lines changed: 25 additions & 4 deletions

File tree

.github/dependabot.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,7 @@ updates:
1010
- dependency-name: airtap
1111
- dependency-name: nyc
1212
- dependency-name: standard
13+
14+
# Pinned to 1.1.10 for browser compatibility (later versions depend
15+
# on `queue-microtask` which uses arrow functions and promises).
16+
- dependency-name: run-parallel

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,13 @@
4040
"memdown": "^5.0.0",
4141
"nyc": "^14.0.0",
4242
"pinkie": "^2.0.4",
43-
"run-parallel": "^1.1.9",
43+
"run-parallel": "1.1.10",
4444
"run-series": "^1.1.8",
4545
"safe-buffer": "^5.1.0",
4646
"simple-concat": "^1.0.0",
4747
"sinon": "^7.4.2",
4848
"standard": "^15.0.0",
49-
"tape": "^4.7.0",
49+
"tape": "^5.2.2",
5050
"trickle": "0.0.2"
5151
},
5252
"hallmark": {

test/init-test.js

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,15 @@ var memdown = require('memdown')
44
module.exports = function (test, testCommon) {
55
test('Init & open(): levelup()', function (t) {
66
t.is(typeof levelup, 'function')
7-
t.is(levelup.length, 3) // db, options & callback arguments
8-
t.throws(levelup, /^InitializationError/) // no db
7+
8+
// db, options & callback arguments
9+
t.is(levelup.length, 3)
10+
11+
// no db
12+
throws(t, levelup, function (err) {
13+
return /^InitializationError/.test(err)
14+
})
15+
916
t.end()
1017
})
1118

@@ -107,3 +114,13 @@ module.exports = function (test, testCommon) {
107114
})
108115
})
109116
}
117+
118+
function throws (t, fn, verify) {
119+
try {
120+
fn()
121+
} catch (err) {
122+
return verify(err)
123+
}
124+
125+
t.fail('did not throw')
126+
}

0 commit comments

Comments
 (0)