fix(tui): replace # type: ignore with setattr in TDD regression test steps
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 53s
CI / quality (pull_request) Successful in 1m11s
CI / lint (pull_request) Failing after 1m23s
CI / typecheck (pull_request) Successful in 1m29s
CI / security (pull_request) Successful in 1m29s
CI / helm (pull_request) Successful in 48s
CI / coverage (pull_request) Has been skipped
CI / push-validation (pull_request) Successful in 31s
CI / e2e_tests (pull_request) Successful in 4m2s
CI / integration_tests (pull_request) Successful in 4m53s
CI / unit_tests (pull_request) Successful in 6m5s
CI / docker (pull_request) Has been skipped
CI / status-check (pull_request) Failing after 3s
CI / benchmark-publish (pull_request) Has been skipped
CI / build (pull_request) Successful in 53s
CI / quality (pull_request) Successful in 1m11s
CI / lint (pull_request) Failing after 1m23s
CI / typecheck (pull_request) Successful in 1m29s
CI / security (pull_request) Successful in 1m29s
CI / helm (pull_request) Successful in 48s
CI / coverage (pull_request) Has been skipped
CI / push-validation (pull_request) Successful in 31s
CI / e2e_tests (pull_request) Successful in 4m2s
CI / integration_tests (pull_request) Successful in 4m53s
CI / unit_tests (pull_request) Successful in 6m5s
CI / docker (pull_request) Has been skipped
CI / status-check (pull_request) Failing after 3s
This commit is contained in:
@@ -1,11 +1,10 @@
|
||||
"""Step definitions for tdd_tui_suggestions_query_extraction_4741.feature.
|
||||
|
||||
Regression test for issue #4741:
|
||||
on_input_submitted must extract only the @token text (without the @ sign and
|
||||
without surrounding non-reference words) as the query passed to suggestions().
|
||||
|
||||
Previously, text.replace("@", "").strip() was used, which corrupted the query
|
||||
by including all non-reference words from the prompt.
|
||||
on_input_submitted must extract only the @token text (without the @
|
||||
sign and without surrounding non-reference words) as the query passed to
|
||||
suggestions(). Previously, text.replace("@", "").strip() was used, which
|
||||
corrupted the query by including all non-reference words from the prompt.
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
@@ -91,12 +90,12 @@ def _build_mock_textual_4741() -> dict[str, ModuleType]:
|
||||
def __init__(self, *args: object, **kwargs: object) -> None:
|
||||
self.text = ""
|
||||
|
||||
mock_textual_app.App = MockApp # type: ignore[attr-defined]
|
||||
mock_textual_containers.Vertical = MockVertical # type: ignore[attr-defined]
|
||||
mock_textual_widgets.Header = MockHeader # type: ignore[attr-defined]
|
||||
mock_textual_widgets.Footer = MockFooter # type: ignore[attr-defined]
|
||||
mock_textual_widgets.Static = MockStatic # type: ignore[attr-defined]
|
||||
mock_textual_widgets.TextArea = MockTextArea # type: ignore[attr-defined]
|
||||
setattr(mock_textual_app, "App", MockApp)
|
||||
setattr(mock_textual_containers, "Vertical", MockVertical)
|
||||
setattr(mock_textual_widgets, "Header", MockHeader)
|
||||
setattr(mock_textual_widgets, "Footer", MockFooter)
|
||||
setattr(mock_textual_widgets, "Static", MockStatic)
|
||||
setattr(mock_textual_widgets, "TextArea", MockTextArea)
|
||||
|
||||
return {
|
||||
"textual": mock_textual,
|
||||
|
||||
Reference in New Issue
Block a user