From 6b974dc9cb48e6af8e4ea9410141168208e7ca06 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 8 Feb 2014 20:49:12 -0500 Subject: tests: skip iostat-dependent tests Debian GNU/kFreeBSD still does not have iostat :< --- test/mgmt.rb | 3 ++- test/mgmt_auto_adjust.rb | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/test/mgmt.rb b/test/mgmt.rb index c3c6a66..67ffca1 100644 --- a/test/mgmt.rb +++ b/test/mgmt.rb @@ -332,7 +332,8 @@ class TestMgmt < Test::Unit::TestCase assert_nil lines.grep(/\b#{max + 1}\b/)[0] assert File.exist?("#@tmpdir/dev#{max}/usage") assert ! File.exist?("#@tmpdir/dev#{max + 1}/usage") - end + end if `which iostat 2>/dev/null`.chomp.size != 0 && + RUBY_PLATFORM !~ /kfreebsd-gnu/ def test_iostat_watch Dir.mkdir("#@tmpdir/dev666") diff --git a/test/mgmt_auto_adjust.rb b/test/mgmt_auto_adjust.rb index f2e01d6..8f89228 100644 --- a/test/mgmt_auto_adjust.rb +++ b/test/mgmt_auto_adjust.rb @@ -76,7 +76,8 @@ class TestMgmtAutoAdjust < Test::Unit::TestCase assert_operator cur_threads, :>, prev_threads, "prev_threads=#{cur_threads} > prev_threads=#{prev_threads}" assert_match(%r{updating server aio_threads=20}, File.read(@err.path)) - end + end if `which iostat 2>/dev/null`.chomp.size != 0 && + RUBY_PLATFORM !~ /kfreebsd-gnu/ def test_aio_threads_auto_adjust_warn @client.write "server aio_threads = 1\r\n" -- cgit v1.2.3-24-ge0c7