()
| 86 | |
| 87 | |
| 88 | def create_tests(): |
| 89 | for filename in glob.glob(os.path.join(_TEST_PATH, "legacy", "*.json")): |
| 90 | test_suffix, _ = os.path.splitext(os.path.basename(filename)) |
| 91 | with open(filename) as auth_tests: |
| 92 | test_cases = json.load(auth_tests)["tests"] |
| 93 | for test_case in test_cases: |
| 94 | if test_case.get("optional", False): |
| 95 | continue |
| 96 | test_method = create_test(test_case) |
| 97 | name = str(test_case["description"].lower().replace(" ", "_")) |
| 98 | setattr(TestAuthSpec, f"test_{test_suffix}_{name}", test_method) |
| 99 | |
| 100 | |
| 101 | create_tests() |
no test coverage detected