mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
tests: show timing info in the output of run_project_folders_test.v
This commit is contained in:
parent
1af94c7edf
commit
0ef8382824
@ -1,4 +1,5 @@
|
||||
import os
|
||||
import time
|
||||
import term
|
||||
|
||||
const vexe = os.getenv('VEXE')
|
||||
@ -24,13 +25,15 @@ fn test_v_profile_works() ? {
|
||||
for folder_path in folder_paths {
|
||||
local_path := folder_path.replace(vroot + os.path_separator, '').replace('\\',
|
||||
'/')
|
||||
println('..... v run $local_path/')
|
||||
println('........... v run $local_path/')
|
||||
t := time.ticks()
|
||||
res := os.execute('${os.quoted_path(vexe)} run ${os.quoted_path(folder_path)}')
|
||||
delta := time.ticks() - t
|
||||
// eprintln('res: $res')
|
||||
assert res.exit_code == 0
|
||||
assert res.output.len > 0
|
||||
assert res.output.contains('OK')
|
||||
term.clear_previous_line()
|
||||
println('${term.bold('OK')} v run $local_path/')
|
||||
println('${term.bold('OK')} in ${delta:4}ms v run $local_path/')
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user