Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pre-commit.ci] pre-commit autoupdate #16

Merged
merged 3 commits into from
Sep 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ fail_fast: false
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: 'v0.5.4'
rev: 'v0.6.4'
hooks:
- id: ruff
- repo: https://github.com/pre-commit/pre-commit-hooks
Expand Down
4 changes: 2 additions & 2 deletions trolldb/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from trolldb.test_utils.mongodb_instance import running_prepared_database_context


@pytest.fixture()
@pytest.fixture
def caplog(caplog: LogCaptureFixture):
"""This overrides the actual pytest ``caplog`` fixture.

Expand Down Expand Up @@ -50,7 +50,7 @@ async def mongodb_fixture(_run_mongodb_server_instance):
yield


@pytest.fixture()
@pytest.fixture
def check_log(caplog) -> Callable:
"""A fixture to check the logs. It relies on the ``caplog`` fixture.

Expand Down
12 changes: 6 additions & 6 deletions trolldb/tests/test_recorder.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from trolldb.test_utils.mongodb_instance import running_prepared_database_context


@pytest.fixture()
@pytest.fixture
def file_message(tmp_data_filename):
"""Create a string for a file message."""
return ('pytroll://segment/raster/L2/SAR file [email protected] 2019-11-05T13:00:10.366023 v1.01 '
Expand All @@ -27,7 +27,7 @@ def file_message(tmp_data_filename):
'"polarization": "hh", "sensor": "sar-c", "format": "GeoTIFF", "pass_direction": "ASCENDING"}')


@pytest.fixture()
@pytest.fixture
def dataset_message(tmp_data_filename):
"""Create a string for a file message."""
return ('pytroll://segment/raster/L2/SAR dataset [email protected] 2019-11-05T13:00:10.366023 v1.01 '
Expand All @@ -38,7 +38,7 @@ def dataset_message(tmp_data_filename):
'"polarization": "hh", "sensor": "sar-c", "format": "GeoTIFF", "pass_direction": "ASCENDING"}')


@pytest.fixture()
@pytest.fixture
def del_message(tmp_data_filename):
"""Create a string for a delete message."""
return ('pytroll://deletion del [email protected] 2019-11-05T13:00:10.366023 v1.01 '
Expand All @@ -49,21 +49,21 @@ def del_message(tmp_data_filename):
'"polarization": "hh", "sensor": "sar-c", "format": "GeoTIFF", "pass_direction": "ASCENDING"}')


@pytest.fixture()
@pytest.fixture
def unknown_message(tmp_data_filename):
"""Create a string for an unknown message."""
return ("pytroll://deletion some_unknown_key [email protected] 2019-11-05T13:00:10.366023 v1.01 "
"application/json {}")


@pytest.fixture()
@pytest.fixture
def tmp_data_filename(tmp_path):
"""Create a filename for the messages."""
filename = "20191103_153936-s1b-ew-hh.tiff"
return tmp_path / filename


@pytest.fixture()
@pytest.fixture
def config_file(tmp_path):
"""A fixture to create a config file for the tests."""
return create_config_file(tmp_path)
Expand Down