mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-19 06:01:05 +08:00
feat(go-agent): Ported retrieval node, added Keenable web search tool (#16396)
Ported retrieval node, added Keenable web search tool - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@@ -103,7 +103,7 @@ class TestDatasetsDelete:
|
||||
payload = {"ids": ["not_uuid"]}
|
||||
with pytest.raises(Exception) as exception_info:
|
||||
client.delete_datasets(**payload)
|
||||
assert "Invalid UUID1 format" in str(exception_info.value), str(exception_info.value)
|
||||
assert "Invalid UUID format" in str(exception_info.value), str(exception_info.value)
|
||||
|
||||
datasets = client.list_datasets()
|
||||
assert len(datasets) == 1, str(datasets)
|
||||
@@ -114,7 +114,7 @@ class TestDatasetsDelete:
|
||||
payload = {"ids": [uuid.uuid4().hex]}
|
||||
with pytest.raises(Exception) as exception_info:
|
||||
client.delete_datasets(**payload)
|
||||
assert "Invalid UUID1 format" in str(exception_info.value), str(exception_info.value)
|
||||
assert "lacks permission for dataset" in str(exception_info.value), str(exception_info.value)
|
||||
|
||||
@pytest.mark.p2
|
||||
@pytest.mark.usefixtures("add_dataset_func")
|
||||
|
||||
@@ -250,14 +250,14 @@ class TestDatasetsList:
|
||||
params = {"id": "not_uuid"}
|
||||
with pytest.raises(Exception) as exception_info:
|
||||
client.list_datasets(**params)
|
||||
assert "Invalid UUID1 format" in str(exception_info.value), str(exception_info.value)
|
||||
assert "Invalid UUID format" in str(exception_info.value), str(exception_info.value)
|
||||
|
||||
@pytest.mark.p2
|
||||
def test_id_not_uuid1(self, client):
|
||||
params = {"id": uuid.uuid4().hex}
|
||||
with pytest.raises(Exception) as exception_info:
|
||||
client.list_datasets(**params)
|
||||
assert "Invalid UUID1 format" in str(exception_info.value), str(exception_info.value)
|
||||
assert "lacks permission for dataset" in str(exception_info.value), str(exception_info.value)
|
||||
|
||||
@pytest.mark.p2
|
||||
def test_id_wrong_uuid(self, client):
|
||||
@@ -271,7 +271,7 @@ class TestDatasetsList:
|
||||
params = {"id": ""}
|
||||
with pytest.raises(Exception) as exception_info:
|
||||
client.list_datasets(**params)
|
||||
assert "Invalid UUID1 format" in str(exception_info.value), str(exception_info.value)
|
||||
assert "Invalid UUID format" in str(exception_info.value), str(exception_info.value)
|
||||
|
||||
@pytest.mark.p2
|
||||
def test_id_none(self, client):
|
||||
|
||||
Reference in New Issue
Block a user