mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
ruby: Simplify and fix regression test.
This test failed on ppc64le with:
Failure:
</wrong argument type Fixnum \(expected Array\)/> was expected to be =~
<"wrong argument type Integer (expected Array)">.
In addition the test generated a warning:
tc_800_rhbz507346.rb:29: warning: ambiguous first argument; put parentheses or a space even after `/' operator
This commit fixes both of these and also makes it simpler and faster
by not bothering to launch the appliance.
Fixes commit 227b1eea90.
This commit is contained in:
@@ -20,12 +20,10 @@ require File::join(File::dirname(__FILE__), 'test_helper')
|
||||
class Test800RHBZ507346 < MiniTest::Unit::TestCase
|
||||
def test_800_rhbz507346
|
||||
g = Guestfs::Guestfs.new()
|
||||
g.add_drive_scratch(10*1024*1024)
|
||||
g.launch()
|
||||
|
||||
exception = assert_raises TypeError do
|
||||
g.command(1)
|
||||
g.parse_environment_list(1)
|
||||
end
|
||||
assert_match /wrong argument type Fixnum \(expected Array\)/, exception.message
|
||||
assert_match(/wrong argument type .* \(expected Array\)/,
|
||||
exception.message)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user