From bd5ea18a6c50f53a0a5be6381ef4d18331e2d72a Mon Sep 17 00:00:00 2001 From: ccurme Date: Wed, 30 Oct 2024 11:50:51 -0400 Subject: [PATCH] groq[patch]: update standard tests (#27744) - Add xfail on integration test (fails [> 50% of the time](https://github.com/langchain-ai/langchain/actions/workflows/scheduled_test.yml)); - Remove xfail on passing unit test. --- .../groq/tests/integration_tests/test_standard.py | 9 +++++++++ libs/partners/groq/tests/unit_tests/test_standard.py | 5 ----- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/libs/partners/groq/tests/integration_tests/test_standard.py b/libs/partners/groq/tests/integration_tests/test_standard.py index 38fe554c5c7..d34257b4c52 100644 --- a/libs/partners/groq/tests/integration_tests/test_standard.py +++ b/libs/partners/groq/tests/integration_tests/test_standard.py @@ -49,3 +49,12 @@ class TestGroqLlama(BaseTestGroq): ) def test_tool_message_histories_string_content(self, model: BaseChatModel) -> None: super().test_tool_message_histories_string_content(model) + + @pytest.mark.xfail( + reason=( + "Sometimes fails with 'Failed to call a function. " + "Please adjust your prompt.'" + ) + ) + def test_bind_runnables_as_tools(self, model: BaseChatModel) -> None: + super().test_bind_runnables_as_tools(model) diff --git a/libs/partners/groq/tests/unit_tests/test_standard.py b/libs/partners/groq/tests/unit_tests/test_standard.py index db84602711f..939d817499e 100644 --- a/libs/partners/groq/tests/unit_tests/test_standard.py +++ b/libs/partners/groq/tests/unit_tests/test_standard.py @@ -2,7 +2,6 @@ from typing import Type -import pytest from langchain_core.language_models import BaseChatModel from langchain_standard_tests.unit_tests.chat_models import ( ChatModelUnitTests, @@ -15,7 +14,3 @@ class TestGroqStandard(ChatModelUnitTests): @property def chat_model_class(self) -> Type[BaseChatModel]: return ChatGroq - - @pytest.mark.xfail(reason="Groq does not support tool_choice='any'") - def test_bind_tool_pydantic(self, model: BaseChatModel) -> None: - super().test_bind_tool_pydantic(model)