Iterate a ternary function through many test cases.
(method, prec, exp_range, restricted_range, itr, stat)
| 1011 | log(err) |
| 1012 | |
| 1013 | def test_ternary(method, prec, exp_range, restricted_range, itr, stat): |
| 1014 | """Iterate a ternary function through many test cases.""" |
| 1015 | if method in TernaryRestricted: |
| 1016 | exp_range = restricted_range |
| 1017 | for op in all_ternary(prec, exp_range, itr): |
| 1018 | t = TestSet(method, op) |
| 1019 | try: |
| 1020 | if not convert(t): |
| 1021 | continue |
| 1022 | callfuncs(t) |
| 1023 | verify(t, stat) |
| 1024 | except VerifyError as err: |
| 1025 | log(err) |
| 1026 | |
| 1027 | if not method.startswith('__'): |
| 1028 | for op in ternary_optarg(prec, exp_range, itr): |
| 1029 | t = TestSet(method, op) |
| 1030 | try: |
| 1031 | if not convert(t): |
| 1032 | continue |
| 1033 | callfuncs(t) |
| 1034 | verify(t, stat) |
| 1035 | except VerifyError as err: |
| 1036 | log(err) |
| 1037 | |
| 1038 | def test_format(method, prec, exp_range, restricted_range, itr, stat): |
| 1039 | """Iterate the __format__ method through many test cases.""" |
nothing calls this directly
no test coverage detected
searching dependent graphs…