about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--guix.scm5
-rw-r--r--tests/test_hello.py8
2 files changed, 12 insertions, 1 deletions
diff --git a/guix.scm b/guix.scm
index 7c58143..a67e737 100644
--- a/guix.scm
+++ b/guix.scm
@@ -333,7 +333,7 @@ access to Gemini models.")
     (build-system python-build-system)
     (arguments
      (list
-      #:tests? #f ; no test suite
+      #:tests? #t
       #:phases
       #~(modify-phases %standard-phases
           (delete 'configure)
@@ -362,6 +362,9 @@ access to Gemini models.")
                 ;; Patch default pubmed path to store location
                 (substitute* "more_functions.py"
                   (("\\./minipubmed") pubmed)))))
+          (replace 'check
+            (lambda _
+              (invoke "python" "-m" "unittest" "discover" "-s" "tests" "-v")))
           (replace 'install
             (lambda* (#:key outputs #:allow-other-keys)
               (let ((out (assoc-ref outputs "out")))
diff --git a/tests/test_hello.py b/tests/test_hello.py
new file mode 100644
index 0000000..2af3f3b
--- /dev/null
+++ b/tests/test_hello.py
@@ -0,0 +1,8 @@
+import unittest
+
+class TestHello(unittest.TestCase):
+    def test_hello(self):
+        self.assertEqual("hello", "hello")
+
+if __name__ == "__main__":
+    unittest.main()