diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 072e6dca8..303b69388 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -44,7 +44,7 @@ repos: - id: check-readthedocs - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.9.1 + rev: v0.9.2 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix, --show-fixes] diff --git a/tests/core/test_sql_typing.py b/tests/core/test_sql_typing.py index 8b6ff1a96..de1f0eeff 100644 --- a/tests/core/test_sql_typing.py +++ b/tests/core/test_sql_typing.py @@ -49,7 +49,7 @@ def test_convert_jsonschema_type_to_sql_type( jsonschema_type: dict, sql_type: sa.types.TypeEngine, ): - with pytest.warns(DeprecationWarning): + with pytest.warns(DeprecationWarning, match="Use `JSONSchemaToSQL` instead"): result = th.to_sql_type(jsonschema_type) assert isinstance(result, sql_type.__class__) assert str(result) == str(sql_type) @@ -71,7 +71,7 @@ def test_convert_sql_type_to_jsonschema_type( sql_type: sa.types.TypeEngine, is_of_jsonschema_type: dict, ): - with pytest.warns(DeprecationWarning): + with pytest.warns(DeprecationWarning, match="Use `SQLToJSONSchema` instead"): result = th.to_jsonschema_type(sql_type) assert result == is_of_jsonschema_type diff --git a/tests/samples/test_tap_csv.py b/tests/samples/test_tap_csv.py index 217022f2a..2d387dee8 100644 --- a/tests/samples/test_tap_csv.py +++ b/tests/samples/test_tap_csv.py @@ -87,7 +87,10 @@ def test_tap_stream_transformed_catalog_schema_matches_record( runner: TapTestRunner, stream: CSVStream, ): - with pytest.warns(UserWarning): + with pytest.warns( + UserWarning, + match="Fields in transformed catalog but not in records", + ): super().test_tap_stream_transformed_catalog_schema_matches_record( config, resource, @@ -102,5 +105,8 @@ def test_tap_stream_returns_record( runner: TapTestRunner, stream: CSVStream, ): - with pytest.warns(UserWarning): + with pytest.warns( + UserWarning, + match="No records returned in stream", + ): super().test_tap_stream_returns_record(config, resource, runner, stream)