Skip to content

Commit be714cf

Browse files
committed
Update package.json
1 parent e0296de commit be714cf

File tree

3 files changed

+26
-18
lines changed

3 files changed

+26
-18
lines changed

.prettierignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
.nyc_output/
1+
coverage/

package.json

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,17 @@
55
"license": "MIT",
66
"keywords": [
77
"unist",
8+
"node",
89
"textlint",
9-
"util"
10+
"util",
11+
"utility"
1012
],
1113
"repository": "syntax-tree/unist-util-map",
1214
"bugs": "https://github.com/syntax-tree/unist-util-map/issues",
1315
"author": "azu <[email protected]>",
1416
"contributors": [
1517
16-
"Titus Wormer <[email protected]> (http://wooorm.com)"
18+
"Titus Wormer <[email protected]> (https://wooorm.com)"
1719
],
1820
"files": [
1921
"lib/"
@@ -23,16 +25,24 @@
2325
"object-assign": "^4.0.1"
2426
},
2527
"devDependencies": {
26-
"mocha": "^5.0.0",
27-
"prettier": "^1.12.1",
28-
"remark-cli": "^5.0.0",
29-
"remark-preset-wooorm": "^4.0.0",
30-
"xo": "^0.20.3"
28+
"mocha": "^6.0.0",
29+
"nyc": "^14.0.0",
30+
"prettier": "^1.0.0",
31+
"remark-cli": "^6.0.0",
32+
"remark-preset-wooorm": "^5.0.0",
33+
"xo": "^0.24.0"
3134
},
3235
"scripts": {
33-
"format": "remark . -qfo && prettier --write '**/*.js' && xo --fix",
36+
"format": "remark . -qfo && prettier --write \"**/*.js\" && xo --fix",
3437
"test-api": "mocha",
35-
"test": "npm run format && npm run test-api"
38+
"test-coverage": "nyc --reporter lcov mocha test.js",
39+
"test": "npm run format && npm run test-coverage"
40+
},
41+
"nyc": {
42+
"check-coverage": true,
43+
"lines": 100,
44+
"functions": 100,
45+
"branches": 100
3646
},
3747
"prettier": {
3848
"tabWidth": 2,
@@ -44,11 +54,7 @@
4454
},
4555
"xo": {
4656
"prettier": true,
47-
"esnext": false,
48-
"rules": {
49-
"no-var": "off",
50-
"prefer-arrow-callback": "off"
51-
}
57+
"esnext": false
5258
},
5359
"remarkConfig": {
5460
"plugins": [

test.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ describe('should not traverse into children of filtered out nodes', function() {
2525
value: 'CHANGED'
2626
})
2727
}
28+
2829
// No change
2930
return node
3031
})
@@ -38,7 +39,7 @@ describe('should not traverse into children of filtered out nodes', function() {
3839
{type: 'leaf', value: 'CHANGED'}
3940
]
4041
}
41-
assert.deepEqual(actual, expected)
42+
assert.deepStrictEqual(actual, expected)
4243
})
4344
context('when return null', function() {
4445
it('should map as empty object', function() {
@@ -56,6 +57,7 @@ describe('should not traverse into children of filtered out nodes', function() {
5657
if (node.type === 'leaf') {
5758
return null
5859
}
60+
5961
// No change
6062
return node
6163
})
@@ -69,7 +71,7 @@ describe('should not traverse into children of filtered out nodes', function() {
6971
{}
7072
]
7173
}
72-
assert.deepEqual(actual, expected)
74+
assert.deepStrictEqual(actual, expected)
7375
})
7476
})
7577

@@ -84,7 +86,7 @@ describe('should not traverse into children of filtered out nodes', function() {
8486
const expected = {
8587
value: 'test'
8688
}
87-
assert.deepEqual(actual, expected)
89+
assert.deepStrictEqual(actual, expected)
8890
})
8991
})
9092
})

0 commit comments

Comments
 (0)