From 7c5ede653e5873b53c7c4b06c081f314c9ef640b Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Wed, 5 Oct 2016 10:48:16 -0400 Subject: [PATCH] Add a most basic test suite runner (for doctests only, at the moment). --- makefile | 4 ++++ test/suite.py | 17 +++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 test/suite.py diff --git a/makefile b/makefile index ca68147..f1be9f0 100644 --- a/makefile +++ b/makefile @@ -1,3 +1,7 @@ +.PHONY: check +check: + python test/suite.py + .PHONY: clean clean: rm -r __pycache__ diff --git a/test/suite.py b/test/suite.py new file mode 100644 index 0000000..e66d3ad --- /dev/null +++ b/test/suite.py @@ -0,0 +1,17 @@ +import unittest +import doctest + +# Add '../' to our path. +from site import addsitedir +addsitedir('.') +import cones +import matrices +import symmetric_linear_game + +suite = unittest.TestSuite() +suite.addTest(doctest.DocTestSuite(cones)) +suite.addTest(doctest.DocTestSuite(matrices)) +suite.addTest(doctest.DocTestSuite(symmetric_linear_game)) + +runner = unittest.TextTestRunner(verbosity=2) +runner.run(suite) -- 2.44.2