Consider more block devices.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50253 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a062d71b15
commit
525d2102fc
@ -160,11 +160,7 @@ class TestFileExhaustive < Test::Unit::TestCase
|
|||||||
def blockdev
|
def blockdev
|
||||||
return @blockdev if defined? @blockdev
|
return @blockdev if defined? @blockdev
|
||||||
if /linux/ =~ RUBY_PLATFORM
|
if /linux/ =~ RUBY_PLATFORM
|
||||||
if File.exist? '/dev/loop0'
|
@blockdev = %w[/dev/loop0 /dev/sda /dev/vda /dev/xvda1].find {|f| File.exist? f }
|
||||||
@blockdev = '/dev/loop0'
|
|
||||||
elsif File.exist? '/dev/sda'
|
|
||||||
@blockdev = '/dev/sda'
|
|
||||||
end
|
|
||||||
else
|
else
|
||||||
@blockdev = nil
|
@blockdev = nil
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user