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 tests for macOS

davidmezzetti2dd850426ff4
diff --git a/test/python/testextractor.py b/test/python/testextractor.py
index 06a8e225..6f81e34f 100644
--- a/test/python/testextractor.py
+++ b/test/python/testextractor.py
@@ -2,7 +2,7 @@
Extractor module tests
"""
-# import platform
+import platform
import unittest
from txtai.embeddings import Embeddings
@@ -81,7 +81,7 @@ class TestExtractor(unittest.TestCase):
answers = self.extractor([(question, question, question, False)], self.data)
self.assertIsNone(answers[0][1])
- # @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
+ @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
def testQuantize(self):
"""
Test qa extraction backed by a quantized model
diff --git a/test/python/testquantization.py b/test/python/testquantization.py
index ebdb93b5..7289ee50 100644
--- a/test/python/testquantization.py
+++ b/test/python/testquantization.py
@@ -2,7 +2,7 @@
Quantization module tests
"""
-# import platform
+import platform
import unittest
from transformers import AutoModel
@@ -15,7 +15,7 @@ class TestQuantization(unittest.TestCase):
Quantization tests
"""
- # @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
+ @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
def testModel(self):
"""
Tests quantizing a model through HFModel.
@@ -25,7 +25,7 @@ class TestQuantization(unittest.TestCase):
model = model.prepare(AutoModel.from_pretrained("google/bert_uncased_L-2_H-128_A-2"))
self.assertIsNotNone(model)
- # @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
+ @unittest.skipIf(platform.system() == "Darwin", "Quantized models not supported on macOS")
def testPipeline(self):
"""
Tests quantizing a model through HFPipeline.