Skip to content

armgit / txtai

Public Imported from GitHub
0

💡 All-in-one AI framework for semantic search, LLM orchestration and language model workflows

Skip Milvus tests on Windows #1156

davidmezzetti2c6ec162d07f
diff --git a/test/python/testann/testdense.py b/test/python/testann/testdense.py
index d6357559..bc39d649 100644
--- a/test/python/testann/testdense.py
+++ b/test/python/testann/testdense.py
@@ -196,6 +196,27 @@ class TestDense(unittest.TestCase):
# Test with custom settings
self.runTests("hnsw", {"hnsw": {"efconstruction": 100, "m": 4, "randomseed": 0, "efsearch": 5}})
+ @unittest.skipIf(os.name == "nt", "Skip Milvus on Windows")
+ def testMilvus(self):
+ """
+ Test milvus-lite backend
+ """
+
+ self.runTests("milvus")
+
+ @unittest.skipIf(os.name == "nt", "Skip Milvus on Windows")
+ def testMilvusCustom(self):
+ """
+ Test milvus-lite backend with custom settings
+ """
+
+ self.runTests("milvus", {"milvus": {"m": 16}})
+
+ # Test invalid file path handled
+ with self.assertRaises(FileNotFoundError):
+ ann = ANNFactory.create({"backend": "milvus"})
+ ann.load("non-exist-path")
+
def testNotImplemented(self):
"""
Test exceptions for non-implemented methods
@@ -401,25 +422,6 @@ class TestDense(unittest.TestCase):
self.runTests("turbovec")
- def testMilvus(self):
- """
- Test milvus-lite backend
- """
-
- self.runTests("milvus")
-
- def testMilvusCustom(self):
- """
- Test milvus-lite backend with custom settings
- """
-
- self.runTests("milvus", {"milvus": {"m": 16}})
-
- # Test invalid file path handled
- with self.assertRaises(FileNotFoundError):
- ann = ANNFactory.create({"backend": "milvus"})
- ann.load("non-exist-path")
-
def testZvec(self):
"""
Test zvec backend