Esempio n. 1
0
def run_full_test_suite():
    """Run the complete test suite for PyGMO."""
    import sys
    from PyGMO import test
    from PyGMO.test._hypervolume_tests import get_hv_suite
    from PyGMO.test._topology_tests import get_topology_test_suite
    from PyGMO.test._archipelago_tests import get_archipelago_test_suite
    suite = _ut.TestLoader().loadTestsFromModule(test)

    # Add external suites explicitly
    suite.addTests(get_hv_suite())
    suite.addTests(get_topology_test_suite())
    suite.addTests(get_archipelago_test_suite())

    successful = _ut.TextTestRunner(verbosity=2).run(suite).wasSuccessful()
    sys.exit(0 if successful else 1)
Esempio n. 2
0
def run_topology_test_suite():
    """Run the topology test suite."""
    from PyGMO.test._topology_tests import get_topology_test_suite
    _ut.TextTestRunner(verbosity=2).run(get_topology_test_suite())