Ruff pass before starting Aider #72
|
@ -23,10 +23,11 @@ class TestSolveIssueInRepository:
|
||||||
self.issue_description = "This is a test issue"
|
self.issue_description = "This is a test issue"
|
||||||
self.issue_number = "123"
|
self.issue_number = "123"
|
||||||
|
|
||||||
|
@patch('aider_gitea.secrets.llm_api_key', return_value="fake-api-key")
|
||||||
@patch('aider_gitea.run_cmd')
|
@patch('aider_gitea.run_cmd')
|
||||||
@patch('aider_gitea.push_changes')
|
@patch('aider_gitea.push_changes')
|
||||||
@patch('subprocess.run')
|
@patch('subprocess.run')
|
||||||
def test_solve_issue_with_aider_changes(self, mock_subprocess_run, mock_push_changes, mock_run_cmd):
|
def test_solve_issue_with_aider_changes(self, mock_subprocess_run, mock_push_changes, mock_run_cmd, mock_llm_api_key):
|
||||||
# Setup mocks
|
# Setup mocks
|
||||||
mock_run_cmd.return_value = True
|
mock_run_cmd.return_value = True
|
||||||
mock_push_changes.return_value = True
|
mock_push_changes.return_value = True
|
||||||
|
@ -53,10 +54,11 @@ class TestSolveIssueInRepository:
|
||||||
assert mock_run_cmd.call_count >= 8 # Verify all expected commands were run
|
assert mock_run_cmd.call_count >= 8 # Verify all expected commands were run
|
||||||
mock_push_changes.assert_called_once()
|
mock_push_changes.assert_called_once()
|
||||||
|
|
||||||
|
@patch('aider_gitea.secrets.llm_api_key', return_value="fake-api-key")
|
||||||
@patch('aider_gitea.run_cmd')
|
@patch('aider_gitea.run_cmd')
|
||||||
@patch('aider_gitea.push_changes')
|
@patch('aider_gitea.push_changes')
|
||||||
@patch('subprocess.run')
|
@patch('subprocess.run')
|
||||||
def test_solve_issue_without_aider_changes(self, mock_subprocess_run, mock_push_changes, mock_run_cmd):
|
def test_solve_issue_without_aider_changes(self, mock_subprocess_run, mock_push_changes, mock_run_cmd, mock_llm_api_key):
|
||||||
# Setup mocks
|
# Setup mocks
|
||||||
mock_run_cmd.return_value = True
|
mock_run_cmd.return_value = True
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user