forked from Rockachopa/Timmy-time-dashboard
Add pre-commit hook enforcing 30s test suite time limit (#132)
This commit is contained in:
committed by
GitHub
parent
aff3edb06a
commit
2b97da9e9c
@@ -3,19 +3,19 @@ from unittest.mock import MagicMock, patch
|
||||
from typer.testing import CliRunner
|
||||
|
||||
from timmy.cli import app
|
||||
from timmy.prompts import TIMMY_STATUS_PROMPT
|
||||
from timmy.prompts import STATUS_PROMPT
|
||||
|
||||
runner = CliRunner()
|
||||
|
||||
|
||||
def test_status_uses_status_prompt():
|
||||
"""status command must pass TIMMY_STATUS_PROMPT to the agent."""
|
||||
"""status command must pass STATUS_PROMPT to the agent."""
|
||||
mock_timmy = MagicMock()
|
||||
|
||||
with patch("timmy.cli.create_timmy", return_value=mock_timmy):
|
||||
runner.invoke(app, ["status"])
|
||||
|
||||
mock_timmy.print_response.assert_called_once_with(TIMMY_STATUS_PROMPT, stream=False)
|
||||
mock_timmy.print_response.assert_called_once_with(STATUS_PROMPT, stream=False)
|
||||
|
||||
|
||||
def test_status_does_not_use_inline_string():
|
||||
|
||||
Reference in New Issue
Block a user