aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui/screen.lua
diff options
context:
space:
mode:
authorThiago de Arruda <tpadilha84@gmail.com>2015-01-23 19:00:45 -0300
committerThiago de Arruda <tpadilha84@gmail.com>2015-01-23 19:00:45 -0300
commitcbc23d93b9f8dd8043836fa2d0ca36667a19a849 (patch)
tree23d796c7703f53b9ea26377494b2a5fdb6677a24 /test/functional/ui/screen.lua
parent41225fe4f69b507b020d7bf4033e02d3f4fbdd40 (diff)
downloadrneovim-cbc23d93b9f8dd8043836fa2d0ca36667a19a849.tar.gz
rneovim-cbc23d93b9f8dd8043836fa2d0ca36667a19a849.tar.bz2
rneovim-cbc23d93b9f8dd8043836fa2d0ca36667a19a849.zip
test: Make default screen timeout depend on the VALGRIND env var
While running under valgrind, the screen can take significantly longer to update(especially on travis) so a higher timeout can be required. Also reduce the timeout when not running on valgrind.
Diffstat (limited to 'test/functional/ui/screen.lua')
-rw-r--r--test/functional/ui/screen.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/functional/ui/screen.lua b/test/functional/ui/screen.lua
index 3070412e4d..ef99c2a536 100644
--- a/test/functional/ui/screen.lua
+++ b/test/functional/ui/screen.lua
@@ -85,6 +85,10 @@ Screen.__index = Screen
local debug_screen
+local default_screen_timeout = 2500
+if os.getenv('VALGRIND') then
+ default_screen_timeout = 7500
+end
function Screen.debug(command)
if not command then
@@ -187,7 +191,7 @@ function Screen:wait(check, timeout)
end
return true
end
- run(nil, notification_cb, nil, timeout or 5000)
+ run(nil, notification_cb, nil, timeout or default_screen_timeout)
if not checked then
err = check()
end