summaryrefslogtreecommitdiffstats
path: root/etc/unittest/mocks.py
diff options
context:
space:
mode:
authorHeiner Lohaus <hlohaus@users.noreply.github.com>2024-01-23 12:17:16 +0100
committerHeiner Lohaus <hlohaus@users.noreply.github.com>2024-01-23 12:17:16 +0100
commite4f743881c915ba250b859d01ef78c7b90a96bf5 (patch)
tree22e1897967212a209751880cd6f9e3bac82bb9d9 /etc/unittest/mocks.py
parentCheck for comments in copilot (diff)
downloadgpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar.gz
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar.bz2
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar.lz
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar.xz
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.tar.zst
gpt4free-e4f743881c915ba250b859d01ef78c7b90a96bf5.zip
Diffstat (limited to '')
-rw-r--r--etc/unittest/mocks.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/etc/unittest/mocks.py b/etc/unittest/mocks.py
index a9505997..885bdaee 100644
--- a/etc/unittest/mocks.py
+++ b/etc/unittest/mocks.py
@@ -22,4 +22,12 @@ class AsyncGeneratorProviderMock(AsyncGeneratorProvider):
async def create_async_generator(
model, messages, stream, **kwargs
):
- yield "Mock" \ No newline at end of file
+ yield "Mock"
+
+class ModelProviderMock(AbstractProvider):
+ working = True
+
+ def create_completion(
+ model, messages, stream, **kwargs
+ ):
+ yield model \ No newline at end of file