| 1 | from flasgger.utils import is_openapi3 |
| 2 | |
| 3 | |
| 4 | def test_isopenapi_3_false(): |
| 5 | assert not is_openapi3(None) |
| 6 | assert not is_openapi3("") |
| 7 | assert not is_openapi3(5) |
| 8 | assert not is_openapi3("2.0") |
| 9 | assert not is_openapi3("1") |
| 10 | |
| 11 | |
| 12 | def test_isopenapi_3_true(): |
| 13 | assert is_openapi3("3") |
| 14 | assert is_openapi3("3.3.3.3") |
| 15 | assert is_openapi3(3) |
| 16 | assert is_openapi3(3.0) |