From 0f60aacf93619173cef29eca16480a6ae550b8d3 Mon Sep 17 00:00:00 2001 From: Martin Vidner Date: Wed, 2 Oct 2013 13:38:51 +0200 Subject: [PATCH] Skip Expect tests if the environment is broken. --- agents-perl/testsuite/test-common.exp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/agents-perl/testsuite/test-common.exp b/agents-perl/testsuite/test-common.exp index d6cb3f54f..ac50fd2c9 100644 --- a/agents-perl/testsuite/test-common.exp +++ b/agents-perl/testsuite/test-common.exp @@ -1,5 +1,13 @@ # common setup for test cases of ag_backgound +if { [catch {exec grep devpts.*mode=620 /proc/mounts} ] } { + # Something in our Jenkins instance remounts it with mode 600 + # and then "spawn" fails. + puts "SKIP: need devpts with mode=620." + puts " See also https://bugzilla.redhat.com/show_bug.cgi?id=510183" + exit 77 +} + set prog "../ag_background" set env(PERL5LIB) "../lib" @@ -15,7 +23,7 @@ spawn $prog $argv match_max 100000 set timeout 15 -expect_after { +expect_after { default { puts "OOPS" puts "last matched <<$expect_out(buffer)>>"