From e157dc9c67d59b9ba0d24cd8f8231e30752653aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sa=C3=BAl=20Ibarra=20Corretg=C3=A9?= Date: Tue, 2 Dec 2014 09:24:27 +0100 Subject: [PATCH] test: skip tty test if detected width and height are 0 This happens in certain build environments such as Jenkins if some tweaking is not performed in the host system. PR-URL: https://github.com/libuv/libuv/pull/22 --- test/test-tty.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/test-tty.c b/test/test-tty.c index fb699107..7e1ce266 100644 --- a/test/test-tty.c +++ b/test/test-tty.c @@ -96,6 +96,13 @@ TEST_IMPL(tty) { printf("width=%d height=%d\n", width, height); + if (width == 0 && height == 0) { + /* Some environments such as containers or Jenkins behave like this + * sometimes */ + MAKE_VALGRIND_HAPPY(); + return TEST_SKIP; + } + /* * Is it a safe assumption that most people have terminals larger than * 10x10?