[cig-commits] r6907 - short/3D/PyLith/trunk/unittests/pytests/topology

brad at geodynamics.org brad at geodynamics.org
Wed May 16 15:08:48 PDT 2007


Author: brad
Date: 2007-05-16 15:08:47 -0700 (Wed, 16 May 2007)
New Revision: 6907

Added:
   short/3D/PyLith/trunk/unittests/pytests/topology/testgensimple.py
Log:
Added missing check script.

Added: short/3D/PyLith/trunk/unittests/pytests/topology/testgensimple.py
===================================================================
--- short/3D/PyLith/trunk/unittests/pytests/topology/testgensimple.py	2007-05-16 21:04:06 UTC (rev 6906)
+++ short/3D/PyLith/trunk/unittests/pytests/topology/testgensimple.py	2007-05-16 22:08:47 UTC (rev 6907)
@@ -0,0 +1,69 @@
+#!/usr/bin/env python
+#
+# ======================================================================
+#
+#                           Brad T. Aagaard
+#                        U.S. Geological Survey
+#
+# {LicenseText}
+#
+# ======================================================================
+#
+
+## @file unittests/topology/testdriver.py
+
+## @brief Python application for testing topology code.
+
+from pyre.applications.Script import Script
+
+import unittest
+
+class TestApp(Script):
+  """
+  Test application.
+  """
+
+  # PUBLIC METHODS /////////////////////////////////////////////////////
+
+  def __init__(self, name="testapp"):
+    """
+    Constructor.
+    """
+    Script.__init__(self, name)
+    return
+
+
+  def main(self):
+    """
+    Run the application.
+    """
+    from pylith.utils.PetscManager import PetscManager
+    manager = PetscManager()
+    manager.initialize()
+    unittest.TextTestRunner(verbosity=2).run(self._suite())
+    manager.finalize()
+    return
+
+
+  # PRIVATE METHODS ////////////////////////////////////////////////////
+
+  def _suite(self):
+    """
+    Setup the test suite.
+    """
+
+    suite = unittest.TestSuite()
+
+    from TestMeshGenSimple import TestMeshGenSimple
+    suite.addTest(unittest.makeSuite(TestMeshGenSimple))
+
+    return suite
+
+
+# ----------------------------------------------------------------------
+if __name__ == '__main__':
+  app = TestApp()
+  app.run()
+
+
+# End of file 


Property changes on: short/3D/PyLith/trunk/unittests/pytests/topology/testgensimple.py
___________________________________________________________________
Name: svn:executable
   + *



More information about the cig-commits mailing list