Swarm-NG  1.1
How to Test Swarm

The Swarm source distribution contains various test suites for testing Swarm's functionality.

Swarm Tests

Once the build process is finished successfully, you may test the installation by the following three mechanisms:

Running the default test set

There is a default set of tests that you can run by simpily type:

make test 

Running Python tests separately

Python tests are included in the master make test, but the individual Python tests are not shown. To run Python tests separately and see their status, run

make pytest

Running special test set

Besides the default test suite, Swarm provides options for users to select different test parameters or different swarm components for testing via swarm configuration. The options are listed below. The values displayed for each options are the default values.

  • Test all integrators versus all number of bodies
    TEST_integrator_nbod:BOOL=TRUE
    
  • List of integrators to be tested vs. nbod
    TEST_integrator_nbod_list:STRING=CPU;Runge_Kutta_Fixed_Time_Step;Runge_Kutta_Adaptive_Time_Step;mvs
    
  • Test the monitors against different number of bodies
    TEST_monitors_nbod:BOOL=FALSE
    
  • Test stability of all integrators
    TEST_stability:BOOL=FALSE
    
  • Duration of the stability test
    TEST_stability_duration:STRING=100
    
  • List of integrators to be tested for stability
    TEST_stability_list:STRING=Runge_Kutta_Fixed_Time_Step;Runge_Kutta_Adaptive_Time_Step
    
  • Number of systems for stability test
    TEST_stability_nsys:STRING=16
    

Build your own tests

Swarm also allows users to make their own tests.

Test output

After running swarm tests, three output files will be generated in <build directory>/Testing/Temporary.

- \c CTestCostData.txt: contains the testing time for each tests in the 

test suite.

- \c LastTest.log: captures the detailed information about each tests, such 

as the name of the test, test command line, start time and end time, time elapsed, and other run time outputs. In addition, it indicates if a test succeeded or failed.

- \c LastTestsFailed.log: lists all the tests that failed during 'make test'

execution.

Benchmarking

If you want to test the computational capacity of your system, type:

make benchmark