Comparing version 0.7.0 to 0.8.0
@@ -10,2 +10,3 @@ /*globals rabbitmq_test_bindings: false, | ||
var qlobber = require('../..'); | ||
var MapValQlobber = require('../options/_mapval').MapValQlobber; | ||
var expect = require('chai').expect; | ||
@@ -57,2 +58,6 @@ require('../../test/rabbitmq.js'); | ||
} | ||
else if (options.Matcher === MapValQlobber) | ||
{ | ||
vals = Array.from(vals.keys()).sort(); | ||
} | ||
@@ -81,9 +86,13 @@ expect(vals).to.eql(test[1].sort()); | ||
if (options.Matcher === qlobber.Qlobber) | ||
if (options.Matcher === qlobber.QlobberDedup) | ||
{ | ||
vals = remove_duplicates(vals); | ||
vals = Array.from(vals).sort(); | ||
} | ||
else if (options.Matcher === MapValQlobber) | ||
{ | ||
vals = Array.from(vals.keys()).sort(); | ||
} | ||
else | ||
{ | ||
vals = Array.from(vals).sort(); | ||
vals = remove_duplicates(vals); | ||
} | ||
@@ -90,0 +99,0 @@ |
@@ -26,29 +26,33 @@ /*jslint node: true */ | ||
shell: { | ||
exec: { | ||
cover: { | ||
command: './node_modules/.bin/istanbul cover ./node_modules/.bin/grunt -- test' | ||
cmd: "./node_modules/.bin/nyc -x Gruntfile.js -x 'test/**' ./node_modules/.bin/grunt test" | ||
}, | ||
check_cover: { | ||
command: './node_modules/.bin/istanbul check-coverage --statement 100 --branch 100 --function 100 --line 100' | ||
cover_report: { | ||
cmd: './node_modules/.bin/nyc report -r lcov' | ||
}, | ||
cover_check: { | ||
cmd: './node_modules/.bin/nyc check-coverage --statements 100 --branches 100 --functions 100 --lines 100' | ||
}, | ||
coveralls: { | ||
command: 'cat coverage/lcov.info | coveralls' | ||
cmd: 'cat coverage/lcov.info | coveralls' | ||
}, | ||
bench: { | ||
command: './node_modules/.bin/bench -c 20000 -i bench/options/default.js,bench/options/dedup.js -k options bench/add_match_remove bench/match' | ||
cmd: './node_modules/.bin/bench -c 20000 -i bench/options/default.js,bench/options/dedup.js,bench/options/mapval.js -k options bench/add_match_remove bench/match' | ||
}, | ||
'bench-check': { | ||
command: './node_modules/.bin/bench -c 20000 -i bench/options/check.js,bench/options/check-dedup.js -k options bench/add_match_remove bench/match' | ||
cmd: './node_modules/.bin/bench -c 20000 -i bench/options/check.js,bench/options/check-dedup.js,bench/options/check-mapval.js -k options bench/add_match_remove bench/match' | ||
}, | ||
'bench-add-many': { | ||
command: './node_modules/.bin/bench -c 1 -i bench/options/default.js,bench/options/dedup.js -k options bench/add_many.js' | ||
cmd: './node_modules/.bin/bench -c 1 -i bench/options/default.js,bench/options/dedup.js,bench/options/mapval.js -k options bench/add_many.js' | ||
}, | ||
'bench-match-many': { | ||
command: './node_modules/.bin/bench -c 1 -i bench/options/default.js,bench/options/dedup.js -k options bench/match_many.js' | ||
cmd: './node_modules/.bin/bench -c 1 -i bench/options/default.js,bench/options/dedup.js,bench/options/mapval.js -k options bench/match_many.js' | ||
} | ||
@@ -61,3 +65,3 @@ } | ||
grunt.loadNpmTasks('grunt-apidox'); | ||
grunt.loadNpmTasks('grunt-shell'); | ||
grunt.loadNpmTasks('grunt-exec'); | ||
@@ -67,11 +71,13 @@ grunt.registerTask('lint', 'jshint'); | ||
grunt.registerTask('docs', 'apidox'); | ||
grunt.registerTask('coverage', ['shell:cover', 'shell:check_cover']); | ||
grunt.registerTask('coveralls', 'shell:coveralls'); | ||
grunt.registerTask('bench', ['shell:bench', | ||
'shell:bench-add-many', | ||
'shell:bench-match-many']); | ||
grunt.registerTask('bench-check', 'shell:bench-check'); | ||
grunt.registerTask('bench-add-many', 'shell:bench-add-many'); | ||
grunt.registerTask('bench-match-many', 'shell:bench-match-many'); | ||
grunt.registerTask('default', ['jshint', 'mochaTest']); | ||
grunt.registerTask('coverage', ['exec:cover', | ||
'exec:cover_report', | ||
'exec:cover_check']); | ||
grunt.registerTask('coveralls', 'exec:coveralls'); | ||
grunt.registerTask('bench', ['exec:bench', | ||
'exec:bench-add-many', | ||
'exec:bench-match-many']); | ||
grunt.registerTask('bench-check', 'exec:bench-check'); | ||
grunt.registerTask('bench-add-many', 'exec:bench-add-many'); | ||
grunt.registerTask('bench-match-many', 'exec:bench-match-many'); | ||
grunt.registerTask('default', ['lint', 'test']); | ||
}; |
{ | ||
"name": "qlobber", | ||
"description": "Node.js globbing for amqp-like topics", | ||
"version": "0.7.0", | ||
"version": "0.8.0", | ||
"homepage": "https://github.com/davedoesdev/qlobber", | ||
@@ -22,3 +22,3 @@ "author": { | ||
"test": "grunt lint test", | ||
"travis-test": "grunt lint test coverage coveralls" | ||
"coverage": "grunt lint coverage coveralls" | ||
}, | ||
@@ -41,12 +41,12 @@ "directories": { | ||
"grunt": "~1.0.1", | ||
"grunt-contrib-jshint": "~1.0.0", | ||
"grunt-mocha-test": "~0.12.7", | ||
"grunt-apidox": "~0.1.8", | ||
"grunt-shell": "~1.3.0", | ||
"mocha": "~2.4.5", | ||
"chai": "~3.5.0", | ||
"istanbul": "~0.4.2", | ||
"coveralls": "~2.11.8", | ||
"grunt-contrib-jshint": "~1.1.0", | ||
"grunt-mocha-test": "~0.13.2", | ||
"grunt-apidox": "~0.1.10", | ||
"grunt-exec": "~2.0.0", | ||
"mocha": "~3.4.2", | ||
"chai": "~4.0.2", | ||
"nyc": "~11.0.3", | ||
"coveralls": "~2.13.1", | ||
"b": "git://github.com/davedoesdev/b.git" | ||
} | ||
} |
@@ -115,3 +115,3 @@ /*globals rabbitmq_test_bindings : false, | ||
expect(matcher.get_trie()).to.eql({}); | ||
expect(matcher.get_trie().size).to.equal(0); | ||
@@ -118,0 +118,0 @@ rabbitmq_expected_results_after_clear.forEach(function (test) |
@@ -110,3 +110,3 @@ /*globals rabbitmq_test_bindings : false, | ||
expect(matcher.get_trie()).to.eql({}); | ||
expect(matcher.get_trie().size).to.equal(0); | ||
@@ -113,0 +113,0 @@ rabbitmq_expected_results_after_clear.forEach(function (test) |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
161230
37
1667