Skip to content

Commit

Permalink
selftests: Skip partitions test when mkfs not available
Browse files Browse the repository at this point in the history
This test requires mkfs binary in order to run, while it's not really
essential for avocado testing. Let's skip it when it's not available.

Signed-off-by: Lukáš Doktor <[email protected]>
  • Loading branch information
ldoktor committed Jul 4, 2016
1 parent 01be14d commit c80fb3a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions selftests/unit/test_utils_partition.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ class TestPartition(unittest.TestCase):
Unit tests for avocado.utils.partition
"""

@unittest.skipIf(process.system("which mkfs", ignore_status=True),
"mkfs is required for these tests to run.")
@unittest.skipIf(process.system("which mkfs.ext3", ignore_status=True),
"mkfs.ext3 is required for these tests to run.")
def setUp(self):
try:
process.system("/bin/true", sudo=True)
Expand Down

0 comments on commit c80fb3a

Please sign in to comment.