Skip to content

Commit

Permalink
Added raise to power test for FaultReportCoverageTransformerTest
Browse files Browse the repository at this point in the history
  • Loading branch information
NikosDelijohn committed Oct 19, 2024
1 parent 18bf061 commit 016f502
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion src/unit_tests/test_transformers.py
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ def get_parser(self):

factory = transformers.FaultReportTransformerFactory()
return factory("Coverage")

def test_coverage_str_no_quotes_lhs(self):

parser = self.get_parser()
Expand Down Expand Up @@ -254,6 +254,19 @@ def test_coverage_with_format_specifiers_rhs(self):
'Coverage_3': '(FF+CC*2)'}
self.assertEqual(coverage, expected_coverage)

def test_coverage_with_power_operator_rhs(self):

parser = self.get_parser()

coverage_sample = r"""
Coverage {
"Coverage_1" = "FLT(AA ^ BB ^ CC)";
}
"""
coverage = parser.parse(coverage_sample)
expected_coverage = {'Coverage_1': '(AA ** BB ** CC)'}
self.assertEqual(coverage, expected_coverage)

class TraceTransformerCV32E40PTest(unittest.TestCase):

def get_parser(self):
Expand Down

0 comments on commit 016f502

Please sign in to comment.