更新bench app,增加比对结果
This commit is contained in:
parent
6165c92baa
commit
f06e4b2544
|
|
@ -91,7 +91,14 @@ const main = async () => {
|
||||||
const mipInt = Math.floor((sipInt + eipInt) / 2)
|
const mipInt = Math.floor((sipInt + eipInt) / 2)
|
||||||
const mip = intToIp(mipInt)
|
const mip = intToIp(mipInt)
|
||||||
|
|
||||||
await searcher.search(mip)
|
const info = await searcher.search(mip)
|
||||||
|
|
||||||
|
const region = list.slice(2, list.length).join('|')
|
||||||
|
// check the region info
|
||||||
|
if (region !== info.region) {
|
||||||
|
console.log(`failed search(${mip}) with (${region} != ${info.region})`)
|
||||||
|
process.exit(1)
|
||||||
|
}
|
||||||
total++
|
total++
|
||||||
})
|
})
|
||||||
.on('error', err => {
|
.on('error', err => {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue