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

Commit 13f2a29

Browse files
committed
Updated Coveralls test reporting.
1 parent 3542d02 commit 13f2a29

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

algorithms/es5/hasDuplicateCharacters.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@
1818
})
1919
var hasDuplicateCharacters = function hasDuplicateCharacters () {
2020
var s = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ''
21-
var characters = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new Set(s)
22-
return characters.size !== s.length
21+
return new Set(s).size !== s.length
2322
}
2423

2524
exports.default = hasDuplicateCharacters

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"main": "./es.js",
66
"scripts": {
77
"transpile-es5": "node_modules/.bin/shx rm -rf ./algorithms/es5 && node_modules/.bin/shx rm -rf ./test/es5 && node_modules/.bin/shx rm -f ./es5.js && node_modules/.bin/babel ./es.js -o ./es5.js --plugins=babel-plugin-transform-es2015-modules-umd --no-comments && node_modules/.bin/babel ./algorithms/es -d ./algorithms/es5 --plugins=babel-plugin-transform-es2015-modules-umd --no-comments && node_modules/.bin/babel ./test/es -d ./test/es5 --no-comments && node_modules/.bin/replace '/es/' '/es5/' ./es5.js -q && node_modules/.bin/replace 'global.es' 'global.algorithms' ./es5.js -q && node_modules/.bin/replace '../../es' '../../es5' ./test/es5 -r -q && node_modules/.bin/replace 'Algorithm:' 'ES5 Algorithm:' ./test/es5 -r -q && node_modules/.bin/standard --fix --global self --global define --global it --global describe",
8-
"coverage": "node_modules/.bin/nyc report --reporter=text-lcov --require babel-register node_modules/.bin/_mocha ./test/es/*.js | node_modules/.bin/coveralls",
8+
"coverage": "node_modules/.bin/nyc --require babel-register node_modules/.bin/_mocha ./test/es/*.js && node_modules/.bin/nyc report --reporter=text-lcov | node_modules/.bin/coveralls",
99
"test": "npm run transpile-es5 && node_modules/.bin/nyc --require babel-register node_modules/.bin/_mocha ./test/**/*.js"
1010
},
1111
"repository": {

0 commit comments

Comments
 (0)