From 552e5f47e4519ea5229c449004a86171141c846a Mon Sep 17 00:00:00 2001 From: Andres Caicedo Date: Thu, 20 Apr 2023 20:58:53 +0200 Subject: [PATCH] Update test_base_open_api_plugin.py --- tests/unit/models/test_base_open_api_plugin.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/unit/models/test_base_open_api_plugin.py b/tests/unit/models/test_base_open_api_plugin.py index 950a32662383..26f97b5ad261 100644 --- a/tests/unit/models/test_base_open_api_plugin.py +++ b/tests/unit/models/test_base_open_api_plugin.py @@ -10,11 +10,13 @@ class DummyPlugin(BaseOpenAIPlugin): + """A dummy plugin for testing purposes.""" pass @pytest.fixture def dummy_plugin(): + """A dummy plugin for testing purposes.""" manifests_specs_clients = { "manifest": { "name_for_model": "Dummy", @@ -28,22 +30,27 @@ def dummy_plugin(): def test_dummy_plugin_inheritance(dummy_plugin): + """Test that the DummyPlugin class inherits from the BaseOpenAIPlugin class.""" assert isinstance(dummy_plugin, BaseOpenAIPlugin) def test_dummy_plugin_name(dummy_plugin): + """Test that the DummyPlugin class has the correct name.""" assert dummy_plugin._name == "Dummy" def test_dummy_plugin_version(dummy_plugin): + """Test that the DummyPlugin class has the correct version.""" assert dummy_plugin._version == "1.0" def test_dummy_plugin_description(dummy_plugin): + """Test that the DummyPlugin class has the correct description.""" assert dummy_plugin._description == "A dummy plugin for testing purposes" def test_dummy_plugin_default_methods(dummy_plugin): + """Test that the DummyPlugin class has the correct default methods.""" assert not dummy_plugin.can_handle_on_response() assert not dummy_plugin.can_handle_post_prompt() assert not dummy_plugin.can_handle_on_planning()