Merge pull request #7 from ranjib/fix_tests
Tests should not fail if there are pre-existing containers
This commit is contained in:
commit
4e46b12685
|
@ -15,7 +15,7 @@ class TestLXCClassMethods < Test::Unit::TestCase
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_list_containers
|
def test_list_containers
|
||||||
assert_equal([@name], LXC.list_containers)
|
assert(LXC.list_containers.include?('test'))
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_arch_to_personality
|
def test_arch_to_personality
|
||||||
|
|
|
@ -103,7 +103,7 @@ class TestLXCRunning < Test::Unit::TestCase
|
||||||
|
|
||||||
def test_container_listed
|
def test_container_listed
|
||||||
containers = LXC.list_containers
|
containers = LXC.list_containers
|
||||||
assert_equal(1, containers.length)
|
assert(containers.length > 0)
|
||||||
assert_equal(@name, containers.first)
|
assert(containers.include?(@name))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue