summaryrefslogtreecommitdiff
path: root/pbr/tests/test_hooks.py
diff options
context:
space:
mode:
Diffstat (limited to 'pbr/tests/test_hooks.py')
-rw-r--r--pbr/tests/test_hooks.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/pbr/tests/test_hooks.py b/pbr/tests/test_hooks.py
index 0fcf96c..3f74790 100644
--- a/pbr/tests/test_hooks.py
+++ b/pbr/tests/test_hooks.py
@@ -41,7 +41,9 @@
import os
from testtools import matchers
+from testtools import skipUnless
+from pbr import testr_command
from pbr.tests import base
from pbr.tests import util
@@ -66,6 +68,7 @@ class TestHooks(base.BaseTestCase):
assert 'test_hook_1\ntest_hook_2' in stdout
assert return_code == 0
+ @skipUnless(testr_command.have_testr, "testrepository not available")
def test_custom_commands_known(self):
stdout, _, return_code = self.run_setup('--help-commands')
self.assertFalse(return_code)