update:tools/moderation unittest,only async

This commit is contained in:
zhanglei 2023-12-26 19:47:17 +08:00
parent 4f52b47610
commit 1d3f4a77f9

View file

@ -11,21 +11,6 @@ import pytest
from metagpt.tools.moderation import Moderation
@pytest.mark.parametrize(
("content",),
[
[
["I will kill you", "The weather is really nice today", "I want to hit you"],
]
],
)
def test_moderation(content):
moderation = Moderation()
results = moderation.moderation(content=content)
assert isinstance(results, list)
assert len(results) == len(content)
@pytest.mark.asyncio
@pytest.mark.parametrize(
("content",),