Skip to content

Commit

Permalink
Fix nova.tests.test_nova_rootwrap on Fedora 17.
Browse files Browse the repository at this point in the history
Fix bug 992916

This patch resolves a unit test failure on Fedora 17.  The root cause is
that 'sleep' is '/usr/bin/sleep' instead of '/bin/sleep'.  Update the
test to allow that.

Change-Id: I5c8e04baec7159a8c10c9beb96cff58fd383e71c
  • Loading branch information
russellb committed May 2, 2012
1 parent 351e540 commit 994bba6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nova/tests/test_nova_rootwrap.py
Expand Up @@ -69,7 +69,7 @@ def test_KillFilter(self):
p = subprocess.Popen(["/bin/sleep", "5"])
f = filters.KillFilter("/bin/kill", "root",
["-ALRM"],
["/bin/sleep"])
["/bin/sleep", "/usr/bin/sleep"])
usercmd = ['kill', '-9', p.pid]
# Incorrect signal should fail
self.assertFalse(f.match(usercmd))
Expand All @@ -79,7 +79,7 @@ def test_KillFilter(self):

f = filters.KillFilter("/bin/kill", "root",
["-9", ""],
["/bin/sleep"])
["/bin/sleep", "/usr/bin/sleep"])
usercmd = ['kill', '-9', os.getpid()]
# Our own PID does not match /bin/sleep, so it should fail
self.assertFalse(f.match(usercmd))
Expand Down

0 comments on commit 994bba6

Please sign in to comment.