Merge branch 'main' into gl/chore/refactor-cli

# Conflicts:
#	lib/crewai/src/crewai/cli/cli.py
This commit is contained in:
Greyson LaLonde
2026-03-14 22:17:02 -04:00
140 changed files with 16344 additions and 8476 deletions

View File

@@ -28,7 +28,19 @@ class TestPlusAPI(unittest.TestCase):
response = self.api.login_to_tool_repository()
mock_make_request.assert_called_once_with(
"POST", "/crewai_plus/api/v1/tools/login"
"POST", "/crewai_plus/api/v1/tools/login", json={}
)
self.assertEqual(response, mock_response)
@patch("crewai.cli.plus_api.PlusAPI._make_request")
def test_login_to_tool_repository_with_user_identifier(self, mock_make_request):
mock_response = MagicMock()
mock_make_request.return_value = mock_response
response = self.api.login_to_tool_repository(user_identifier="test-hash-123")
mock_make_request.assert_called_once_with(
"POST", "/crewai_plus/api/v1/tools/login", json={"user_identifier": "test-hash-123"}
)
self.assertEqual(response, mock_response)
@@ -67,7 +79,7 @@ class TestPlusAPI(unittest.TestCase):
response = self.api.login_to_tool_repository()
self.assert_request_with_org_id(
mock_client_instance, "POST", "/crewai_plus/api/v1/tools/login"
mock_client_instance, "POST", "/crewai_plus/api/v1/tools/login", json={}
)
self.assertEqual(response, mock_response)