summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorHiroshi SHIBATA <hsbt@ruby-lang.org>2022-08-23 12:49:46 +0900
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2022-08-23 12:49:46 +0900
commit892fe9bbbaa8b1c286d8d5404eb707ad4288a274 (patch)
tree109df5f2c9f4d9c61273204276b04093dc2c5046 /test
parent545c2b0047309e3a94745cea95d36d44f2223276 (diff)
omit all assertions at TestIO_Console#test_intr when running with FreeBSD
Diffstat (limited to 'test')
-rw-r--r--test/io/console/test_io_console.rb20
1 files changed, 11 insertions, 9 deletions
diff --git a/test/io/console/test_io_console.rb b/test/io/console/test_io_console.rb
index b5382555f5..3c44181f2a 100644
--- a/test/io/console/test_io_console.rb
+++ b/test/io/console/test_io_console.rb
@@ -357,6 +357,15 @@ defined?(PTY) and defined?(IO.console) and TestIO_Console.class_eval do
end
def test_intr
+ # This test fails randomly on FreeBSD 13
+ # http://rubyci.s3.amazonaws.com/freebsd13/ruby-master/log/20220304T163001Z.fail.html.gz
+ #
+ # 1) Failure:
+ # TestIO_Console#test_intr [/usr/home/chkbuild/chkbuild/tmp/build/20220304T163001Z/ruby/test/io/console/test_io_console.rb:387]:
+ # <"25"> expected but was
+ # <"-e:12:in `p': \e[1mexecution expired (\e[1;4mTimeout::Error\e[m\e[1m)\e[m">.
+ omit if /freebsd/ =~ RUBY_PLATFORM
+
run_pty("#{<<~"begin;"}\n#{<<~'end;'}") do |r, w, _|
begin;
require 'timeout'
@@ -383,19 +392,12 @@ defined?(PTY) and defined?(IO.console) and TestIO_Console.class_eval do
assert_ctrl("#{cc.ord}", cc, r, w)
assert_ctrl("Interrupt", cc, r, w) unless /linux|solaris/ =~ RUBY_PLATFORM
end
- # This test fails randomly on FreeBSD 13
- # http://rubyci.s3.amazonaws.com/freebsd13/ruby-master/log/20220304T163001Z.fail.html.gz
- #
- # 1) Failure:
- # TestIO_Console#test_intr [/usr/home/chkbuild/chkbuild/tmp/build/20220304T163001Z/ruby/test/io/console/test_io_console.rb:387]:
- # <"25"> expected but was
- # <"-e:12:in `p': \e[1mexecution expired (\e[1;4mTimeout::Error\e[m\e[1m)\e[m">.
- if (cc = ctrl["dsusp"]) && /freebsd/ !~ RUBY_PLATFORM
+ if cc = ctrl["dsusp"]
assert_ctrl("#{cc.ord}", cc, r, w)
assert_ctrl("#{cc.ord}", cc, r, w)
assert_ctrl("#{cc.ord}", cc, r, w)
end
- if (cc = ctrl["lnext"]) && /freebsd/ !~ RUBY_PLATFORM
+ if cc = ctrl["lnext"]
assert_ctrl("#{cc.ord}", cc, r, w)
assert_ctrl("#{cc.ord}", cc, r, w)
assert_ctrl("#{cc.ord}", cc, r, w)