mirror of
https://github.com/neovim/neovim.git
synced 2026-05-04 21:15:09 +00:00
test/old: partial port of patch v8.2.1.0183
Prep for patch v8.2.0511.
This commit is contained in:
@@ -179,7 +179,7 @@ endfunc
|
||||
func s:WaitForCommon(expr, assert, timeout)
|
||||
" using reltime() is more accurate, but not always available
|
||||
let slept = 0
|
||||
if has('reltime')
|
||||
if exists('*reltimefloat')
|
||||
let start = reltime()
|
||||
endif
|
||||
|
||||
@@ -204,7 +204,7 @@ func s:WaitForCommon(expr, assert, timeout)
|
||||
endif
|
||||
|
||||
sleep 10m
|
||||
if has('reltime')
|
||||
if exists('*reltimefloat')
|
||||
let slept = float2nr(reltimefloat(reltime(start)) * 1000)
|
||||
else
|
||||
let slept += 10
|
||||
@@ -220,7 +220,7 @@ endfunc
|
||||
" feeds key-input and resumes process. Return time waited in milliseconds.
|
||||
" Without +timers it uses simply :sleep.
|
||||
func Standby(msec)
|
||||
if has('timers')
|
||||
if has('timers') && exists('*reltimefloat')
|
||||
let start = reltime()
|
||||
let g:_standby_timer = timer_start(a:msec, function('s:feedkeys'))
|
||||
call getchar()
|
||||
|
||||
Reference in New Issue
Block a user