def test_matches__api_level_too_large(self) -> None: filter_ = Filter("myschema", "postgres", VersionMatcher(5, 10, 3)) file_info = FileInfo("", "myschema", "postgres", 7, 4) assert not filter_.matches(file_info)
def test_matches__wrong_dialect(self) -> None: filter_ = Filter("myschema", "postgres", VersionMatcher(5, 10, 3)) file_info = FileInfo("", "myschema", "mysql", 5, 2) assert not filter_.matches(file_info)
def test_matches__min_version_too_large(self) -> None: filter_ = Filter("myschema", "postgres", VersionMatcher(5, 10, 3)) file_info = FileInfo("", "myschema", "postgres", 11, 2) assert not filter_.matches(file_info)
def test_matches__version_matches_upper(self) -> None: filter_ = Filter("myschema", "postgres", VersionMatcher(5, 10, 3)) file_info = FileInfo("", "myschema", "postgres", 10, 2) assert filter_.matches(file_info)