From: Michael Orlitzky Date: Wed, 5 Oct 2016 14:48:16 +0000 (-0400) Subject: Add a most basic test suite runner (for doctests only, at the moment). X-Git-Tag: 0.1.0~219 X-Git-Url: http://gitweb.michael.orlitzky.com/?p=dunshire.git;a=commitdiff_plain;h=7c5ede653e5873b53c7c4b06c081f314c9ef640b Add a most basic test suite runner (for doctests only, at the moment). --- 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)