forked from cleveragents/cleveragents-core
29 lines
1.4 KiB
Gherkin
29 lines
1.4 KiB
Gherkin
Feature: Settings coverage boost
|
|
Additional scenarios that exercise previously uncovered code paths
|
|
in the Settings class (settings.py lines 561-563 and 602-611).
|
|
|
|
Background:
|
|
Given the settings coverage module is imported
|
|
|
|
Scenario: Model validator rejects retry_max_delay less than retry_base_delay
|
|
When I create Settings with retry_max_delay less than retry_base_delay
|
|
Then a ValidationError should be raised about delay ordering
|
|
And the error message should mention both delay values
|
|
|
|
Scenario: repr masks sensitive field values when set
|
|
Given I have a Settings instance with openai_api_key set to a secret value
|
|
When I call repr on the settings instance
|
|
Then the repr output should contain REDACTED for the openai_api_key field
|
|
And the repr output should start with "Settings(" and end with ")"
|
|
|
|
Scenario: repr shows non-sensitive fields normally
|
|
Given I have a Settings instance with default values
|
|
When I call repr on the settings instance
|
|
Then the repr output should contain the env field with its actual value
|
|
And the repr output should not contain REDACTED for non-sensitive fields
|
|
|
|
Scenario: repr shows REDACTED only for non-None sensitive keys
|
|
Given I have a Settings instance where all sensitive keys are None
|
|
When I call repr on the settings instance
|
|
Then the repr output should show None for sensitive key fields without redaction
|