diff --git a/features/steps/tdd_server_connect_atomic_writes_steps.py b/features/steps/tdd_server_connect_atomic_writes_steps.py index 9298fb9b6..2da5951bc 100644 --- a/features/steps/tdd_server_connect_atomic_writes_steps.py +++ b/features/steps/tdd_server_connect_atomic_writes_steps.py @@ -23,7 +23,7 @@ from unittest.mock import patch from behave import given, then, when from behave.runner import Context -from cleveragents.application.services.config_service import ConfigService +from cleveragents.application.services.config_service import ConfigScope, ConfigService from cleveragents.infrastructure.events.reactive import ReactiveEventBus from cleveragents.infrastructure.events.types import EventType @@ -62,11 +62,14 @@ class _FailingConfigService(ConfigService): config_dir=config_dir, config_path=config_path, event_bus=event_bus, + project_root=None, ) self._fail_on_call = fail_on_call_number self._call_count = 0 - def set_value(self, key: str, value: Any) -> None: + def set_value( + self, key: str, value: Any, *, scope: ConfigScope | None = None + ) -> None: """Override set_value to fail on a specific call number.""" self._call_count += 1 if self._call_count == self._fail_on_call: @@ -74,7 +77,7 @@ class _FailingConfigService(ConfigService): f"Simulated disk failure on set_value call #{self._call_count} " f"(key={key!r})" ) - super().set_value(key, value) + super().set_value(key, value, scope=scope) # --------------------------------------------------------------------------- @@ -123,6 +126,7 @@ def step_pre_existing_config(context: Context) -> None: svc = ConfigService( config_dir=context.atomic_config_dir, config_path=context.atomic_config_path, + project_root=None, ) svc.set_value("server.url", _ORIGINAL_URL) svc.set_value("server.namespace", _ORIGINAL_NAMESPACE)