Skip to content
This repository has been archived by the owner on Feb 8, 2022. It is now read-only.

Automated Tests

Philip Maechling edited this page Jan 25, 2017 · 4 revisions

UCVMC distribution contains a set of test programs and scripts. The individual models (e.g. CVM-S4, CVM-H, Cencal) have their own test methods. The UCVMC distribution provides its own automated tests.

Invoking Model Tests

Invoking UCVMC

The standard method for running the UCVMC tests is to build the distribution, setup the required environment variables in .bash_profile including LD_LOIBRAY_PATH and PYTHON_PATH. Then in the home source directory home, the user runs %make check

This command will run the UCVMC unittest, acceptance test suite, and a python acceptance test script. When these are run, the following tests are performed:

Unit Tests

This is a C language test script. It tests for which models are included, but assuming the standard set of models:

  • int test_lib_init()
  • int test_lib_add_model_1d()
  • int test_lib_query_1d()
  • int test_lib_get_model_label_1d()
  • int test_lib_setparam_querymode_gd_1d()
  • int test_lib_setparam_querymode_ge_1d()
  • int test_lib_model_version_1d()
  • int test_lib_add_model_cencal()
  • int test_lib_add_model_cvmh()
  • int test_lib_add_model_cvms()
  • int test_lib_add_model_cvmsi()

Acceptance Tests

This runs 4 tests which are:

  • int test_grid_tool_1d()
  • int test_grid_lib_1d()
  • int suite_grid(const char *xmldir)
  • test_get_time(&suite.exec_time);

accept_test.py

This runs two test scripts:

  • test_vs30_query
  • test_ssh_generate

Validate.ssh

A binary that generates a small scale heterogenity file and then tests to confirm it matches the reference file

Make Check

After installation, user can set the LD_LIB path, and PYTHON PATH. Once they are established, the users can return to the src home directory and run: %make check

This runs the ./unittest, ./accepttest, and the accept_test.py which runs the vs30_query, and validate.ssh programs.

Clone this wiki locally