1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

new benchmark module + make the tests use it

This commit is contained in:
Delyan Angelov
2019-09-16 17:29:06 +03:00
committed by Alexander Medvednikov
parent 3325775944
commit a45895a3af
5 changed files with 148 additions and 46 deletions

View File

@@ -1,7 +1,6 @@
module runner
import os
import time
struct RunnerOptions {
pub:
@@ -71,13 +70,3 @@ pub fn new_options() RunnerOptions {
}
}
pub fn now() i64 {
return time.ticks()
}
pub fn tdiff_in_ms(s string, sticks i64) string {
eticks := time.ticks()
tdiff := (eticks - sticks)
return '${tdiff:6d} ms | $s'
}