Skip to content

Commit

Permalink
Fix test breakage likely caused by an update to pytest
Browse files Browse the repository at this point in the history
  • Loading branch information
glados-verma committed Jun 29, 2024
1 parent 865512a commit 1b777e9
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions openhtf/util/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -660,10 +660,11 @@ class TestCase(unittest.TestCase):

def __init__(self, methodName=None):
super(TestCase, self).__init__(methodName=methodName)
test_method = getattr(self, methodName)
if inspect.isgeneratorfunction(test_method):
raise ValueError('%s yields without @openhtf.util.test.yields_phases' %
methodName)
if methodName != 'runTest':
test_method = getattr(self, methodName)
if inspect.isgeneratorfunction(test_method):
raise ValueError('%s yields without @openhtf.util.test.yields_phases' %
methodName)

def setUp(self):
super(TestCase, self).setUp()
Expand Down

0 comments on commit 1b777e9

Please sign in to comment.