Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
vasinov committed Jun 14, 2023
1 parent fcdaf84 commit b07daa4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/unit/drivers/vector/test_memory_vector_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,14 @@ def test_upsert_multiple(self, driver):
def test_query(self, driver):
driver.upsert_text_artifact(
TextArtifact("foobar"),
namespace="test-namespace"
namespace="test-namespace",
)

assert len(driver.query("foobar")) == 1
assert len(driver.query("foobar", namespace="bad-namespace")) == 0
assert len(driver.query("foobar", namespace="test-namespace")) == 1
assert driver.query("foobar")[0].vector == [0, 1]
assert driver.query("foobar")[0].vector == []
assert driver.query("foobar", include_vectors=True)[0].vector == [0, 1]
assert BaseArtifact.from_json(driver.query("foobar")[0].meta["artifact"]).value == "foobar"

def test_load_entry(self, driver):
Expand Down

0 comments on commit b07daa4

Please sign in to comment.