MCPcopy
hub / github.com/farzher/fuzzysort / testSorting

Function testSorting

test/test.js:379–386  ·  view source on GitHub ↗
(search, ...targets)

Source from the content-addressed store, hash-verified

377assert.count = 0
378
379function testSorting(search, ...targets) {
380 var results = fuzzysort.go(search, targets)
381 results.map(r => r.target)
382 for(var i=0; i<results.length; i++) {
383 var sameorder = results[i] === targets[i]
384 assert(sameorder, search)
385 }
386}
387function testSorting1(search, ...targets) {
388 var results = fuzzysort.go(search, targets)
389 assert(results[0].target===targets[0], search)

Callers

nothing calls this directly

Calls 2

assertFunction · 0.85
goMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…