CIVET Extension

The CIVET extension adds the ability for MooseDocs to download results from a CIVET client (e.g., https://civet.inl.gov) and present them as reports, links, badges, and other information in a MooseDocs page. This extension is most-often used with the Software Quality Assurance Extension.

Extension Configuration

Table 1 lists the available configuration settings for the CIVET extension. These configuration items should be included in the MooseDocs configuration file (e.g., config.yml).

Table 1: Configuration options for the CIVET extension.

KeyDefaultDescription
activeTrueToggle for disabling the extension. This only changes the initial active state, use setActive to control at runtime.
remotes{}Remote CIVET repositories to pull result; each item in the dict should have another dict with a 'url', 'repo', and 'repo_url'.
branchmasterThe main stable branch for extracting test results.
download_test_resultsTrueAutomatically download and aggregate test results for the current merge commits.
generate_test_reportsTrueGenerate test report pages, if results exist from download or local file(s).
test_reports_locationcivetThe local directory where the generated test reports will be inserted.
test_results_cache${HOME}/.local/share/civet/jobsDefault location for downloading CIVET results.

Extension Commands

The following sections provide information regarding each of the commands available to the extension.

Results Inline Linking

The results inline command allows for linking to testing results for the version of the code repository used to build the documentation. It generates a single link displaying the git commit SHA which links to the associated CIVET results for that SHA.

Example 1: Example of the CIVET extension results command.

Table 2: Options for the CIVET extension results command.

KeyDefaultDescription
styleNoneThe style settings that are passed to rendered HTML tag.
classNoneThe class settings to be passed to rendered HTML tag.
idNoneIdentifier to link against this object.
remoteNoneThe category to utilize for remote result lookup, see CivetExtension.
urlNoneOverride for the repository url provided in the 'category' option, e.g. 'https://civet.inl.gov'.
repoNoneOverride for the repository name provided in the 'category' option, e.g. 'idaholab/moose'.

Merge Results Linking

The civet mergeresults command provides a set of links to CIVET results pages for the version of the code repository used to build the documentation (by default). This is similar to the Results Inline Linking command, except multiple links are provided. Each link is labeled using the git SHA associated with the merge event that prompted testing. This means that MOOSE, for example, might have multiple links associated with next, devel, and master testing events associated with a single master branch merge constituting the current version of the code and documentation. If the use_current_hash settings option is set to False, then the most up-to-date version of the these links is retrieved from the online remote repository.

Example 2: Example of the CIVET extension mergeresults command.

schooltip:Inline usage

Note that this command can also be used inline, using the [!civet!mergeresults] syntax.

Table 3: Options for the CIVET extension mergeresults command.

KeyDefaultDescription
styleNoneThe style settings that are passed to rendered HTML tag.
classNoneThe class settings to be passed to rendered HTML tag.
idNoneIdentifier to link against this object.
remoteNoneThe category to utilize for remote result lookup, see CivetExtension.
urlNoneOverride for the repository url provided in the 'category' option, e.g. 'https://civet.inl.gov'.
repoNoneOverride for the repository name provided in the 'category' option, e.g. 'idaholab/moose'.
use_current_hashTrueUse the hash for the current version of the documentation build, otherwise use the most up-to-date hash from the git remote.

Test Results Badges

The badges command allows the display of a badge (or badges) containing the aggregate status of all tests that were completed corresponding to one or more test specifications for the results associated with the version of the code repository used to build the documentation. Clicking on the badge directs the browser to a report page where individual results can be inspected.

Example 3: Examples of the CIVET extension badges command.

With one test specification:

!civet badges tests=kernels/simple_diffusion.test

With two test specifications:

!civet badges tests=kernels/simple_diffusion.test outputs/common.exodus

With one test specification:

With two test specifications:

schooltip:Inline usage

Note that this command can also be used inline, using the [!civet!badges tests=...] syntax.

Table 4: Options for the CIVET extension badges command.

KeyDefaultDescription
styleNoneThe style settings that are passed to rendered HTML tag.
classNoneThe class settings to be passed to rendered HTML tag.
idNoneIdentifier to link against this object.
remoteNoneThe category to utilize for remote result lookup, see CivetExtension.
urlNoneOverride for the repository url provided in the 'category' option, e.g. 'https://civet.inl.gov'.
repoNoneOverride for the repository name provided in the 'category' option, e.g. 'idaholab/moose'.
testsNoneThe name of the test(s) to report.

Test Results Report

The report command generates a table of jobs, associated CIVET recipes, and test statuses for a given test specification. While this command is available for general use within any markdown page, the table generation activity called by this command is generally used within the Test Results Badges command, where a results page is generated for linking to the rendered badge.

Example 4: Example of the CIVET extension report command.

!civet report tests=kernels/simple_diffusion.test

StatusJobRecipe
OK438301104_Test_moose_test
OK438301204_Test_moose_test
OK438301304_Test_moose_test
OK438301404_Test_moose_test
OK438301804_Test_moose_test
OK438302404_Test_moose_test
OK438302506_Test_moose_test
OK438302604_Test_-p_4
OK438302605_Test_-p_6
OK438302606_Test_-p_8
OK438302607_Test_-p_16
OK438302704_Test_distributed_mesh_with_recover
OK438302705_Test_-p_3
OK438302706_Test_-p_5
OK438302707_Test_-p_7
OK438302708_Test_-p_15
OK438302804_Test_-p_4
OK438302805_Test_-p_6
OK438302806_Test_-p_8
OK438302807_Test_-p_16
OK438302904_Test_-p_3
OK438302905_Test_-p_5
OK438302906_Test_-p_7
OK438302907_Test_-p_15
OK438303613_Test_tutorialstutorial02
OK438303812_Test_moose_test
OK438303813_Test_moose_test_-p_2
OK438303814_Test_moose_test_--recover
OK438303907_Test_moose_test_--n-threads_2
OK438303908_Test_moose_test_--distributed-mesh_-p_2
OK438303910_Test_moose_test_--restep
OK438304007_Test_moose_test
OK438304008_Test_moose_test_-p_2
OK438304104_Test_moose_test
OK438304204_Test_moose_test
OK438304706_Test_moose_test
OK438305603_Test_moose_test
OK438305704_Test_-p_2
OK438305804_Test_-p_4
OK438305805_Test_-p_6
OK438305806_Test_-p_8
OK438305807_Test_-p_16
OK438305904_Test_-p_3
OK438305905_Test_-p_5
OK438305906_Test_-p_7
OK438305907_Test_-p_15
OK438306030_Test_mastodon
OK438306039_Test_open_pronghorn
OK438306045_Test_salamander
OK438306054_Test_Stork
OK438306804_Test_-p_4
OK438306805_Test_-p_6
OK438306806_Test_-p_8
OK438306807_Test_-p_16
OK438306904_Test_-p_3
OK438306905_Test_-p_5
OK438306906_Test_-p_7
OK438306907_Test_-p_15
OK438307003_Test_moose_test_and_store
OK438714607_Test_moose_test
OK438714608_Test_moose_test_-p_2
OK438714609_Test_moose_test_--recover
OK438714610_Test_moose_test_--n-threads2
OK438714611_Test_moose_test_--distributed-mesh_-p_2
OK438715007_Test_moose_test
OK438715107_Test_moose_test
OK438715205_Test_moose_test
OK438715206_Test_moose_test_-p_2
OK438715207_Test_moose_test_--recover
OK438715208_Test_moose_test_--n-threads2
OK438715209_Test_moose_test_--distributed-mesh_-p_2
OK438715904_Test_moose_test_--valgrind

Table 5: Options for the CIVET extension report command.

KeyDefaultDescription
styleNoneThe style settings that are passed to rendered HTML tag.
classNoneThe class settings to be passed to rendered HTML tag.
idNoneIdentifier to link against this object.
remoteNoneThe category to utilize for remote result lookup, see CivetExtension.
urlNoneOverride for the repository url provided in the 'category' option, e.g. 'https://civet.inl.gov'.
repoNoneOverride for the repository name provided in the 'category' option, e.g. 'idaholab/moose'.
testsNoneThe name of the test(s) to report.