Building Test via buildtest

This guide will get you familiar with buildtest command line interface. Once you complete this section, you can proceed to writing buildspecs section where we will cover how to write buildspecs.

Once you install buildtest, you should find the buildtest command in your $PATH. You can check the path to buildtest command by running:

$ which buildtest

If you don’t see buildtest go back and install buildtest.

When you clone buildtest, you also get a set of buildspecs that you can run on your system. The buildtest build command is used for building and running tests. Buildtest will read one or more buildspecs file that adheres to one of the buildtest schemas. For a complete list of build options, run buildtest build --help

Build Usage

$ buildtest build --help
usage: buildtest [options] [COMMANDS] build [-h] [-b BUILDSPEC] [-x EXCLUDE] [-e EXECUTOR] [-t TAGS] [-f FILTER]
                                            [--helpfilter] [-k] [--max-pend-time MAX_PEND_TIME]
                                            [--poll-interval POLL_INTERVAL] [--rebuild REBUILD] [-r REPORT]
                                            [-s {parse,build}] [--testdir TESTDIR]

optional arguments:
  -h, --help            show this help message and exit

discover:
  select buildspecs

  -b BUILDSPEC, --buildspec BUILDSPEC
                        Specify a buildspec (file or directory) to build. A buildspec must end in '.yml' extension.
  -x EXCLUDE, --exclude EXCLUDE
                        Exclude one or more buildspecs (file or directory) from processing. A buildspec must end in
                        '.yml' extension.
  -e EXECUTOR, --executor EXECUTOR
                        Discover buildspecs by executor name found in buildspec cache
  -t TAGS, --tags TAGS  Discover buildspecs by tags found in buildspec cache

filter:
  Filter tests

  -f FILTER, --filter FILTER
                        Filter buildspec based on tags, type, or maintainers. Usage: --filter key1=val1,key2=val2
  --helpfilter          Show available filter fields used with --filter option

extra:
  All extra options

  -k, --keep-stage-dir  Keep stage directory after job completion.
  --max-pend-time MAX_PEND_TIME
                        Specify Maximum Pending Time (sec) for job before cancelling job. This only applies for batch
                        job submission.
  --poll-interval POLL_INTERVAL
                        Specify Poll Interval (sec) for polling batch jobs
  --rebuild REBUILD     Rebuild test X number of times. Must be a positive number between [1-50]
  -r REPORT, --report REPORT
                        Specify a report file where tests will be written.
  -s {parse,build}, --stage {parse,build}
                        control behavior of buildtest build
  --testdir TESTDIR     Specify a custom test directory where to write tests. This overrides configuration file and
                        default location.

Building a Test

To build a test, we use the --buildspec or short option -b to specify the path to buildspec file. Let’s see some examples, first we specify a full path to buildspec file. In this example, buildtest will discover buildspecs followed by parsing the test with appropriate schema and generate a shell script that is run by buildtest. You can learn more about build and test process.

$ buildtest build -b $BUILDTEST_ROOT/tutorials/vars.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:15
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                           |
+=================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml |
+-------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml



name            description
--------------  -------------------------------
variables_bash  Declare shell variables in bash

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name           | id       | type   | executor           | tags          | testpath
----------------+----------+--------+--------------------+---------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------
 variables_bash | 1c4ba849 | script | generic.local.bash | ['tutorials'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/vars/variables_bash/1c4ba849/variables_bash_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name           | id       | executor           | status   |   returncode
----------------+----------+--------------------+----------+--------------
 variables_bash | 1c4ba849 | generic.local.bash | PASS     |            0

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 1/1 Percentage: 100.000%
Failed Tests: 0/1 Percentage: 0.000%


Writing Logfile to: /tmp/buildtest_hr_5xctx.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Note

buildtest will only read buildspecs with .yml extension, if you specify a .yaml it will be ignored by buildtest.

The --buildspec option can be used to specify a file or directory path. If you want to build multiple buildspecs in a directory you can specify the directory path and buildtest will recursively search for all .yml files. In the next example, we build all tests in directory general_tests/configuration.

$ buildtest build -b general_tests/configuration/


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:43
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b general_tests/configuration/

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                               |
+=====================================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml             |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml                |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml          |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml           |
+-------------------------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  5
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  5

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml



name                          description
----------------------------  ----------------------------------------------------------------
root_disk_usage               Check root disk usage and report if it exceeds threshold
ulimit_filelock_unlimited     Check if file lock is set to unlimited in ulimits
ulimit_cputime_unlimited      Check if cputime is set to unlimited in ulimits
ulimit_stacksize_unlimited    Check if stack size is set to unlimited in ulimits
ulimit_vmsize_unlimited       Check virtual memory size and check if its set to unlimited
ulimit_filedescriptor_4096    Check if open file descriptors limit is set to 4096
ulimit_max_user_process_2048  Check max number of user process limit is set to 2048
systemd_default_target        check if default target is multi-user.target
ssh_localhost_remotecommand   Test if ssh on localhost works and if we can run remote command.
kernel_swapusage              Retrieve Kernel Swap Usage

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                         | id       | type   | executor           | tags                      | testpath
------------------------------+----------+--------+--------------------+---------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 root_disk_usage              | 3ea2bacf | script | generic.local.bash | ['filesystem', 'storage'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/disk_usage/root_disk_usage/3ea2bacf/root_disk_usage_build.sh
 ulimit_filelock_unlimited    | 6f5a22d8 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_filelock_unlimited/6f5a22d8/ulimit_filelock_unlimited_build.sh
 ulimit_cputime_unlimited     | ff97e86d | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_cputime_unlimited/ff97e86d/ulimit_cputime_unlimited_build.sh
 ulimit_stacksize_unlimited   | 0e951b96 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_stacksize_unlimited/0e951b96/ulimit_stacksize_unlimited_build.sh
 ulimit_vmsize_unlimited      | 74ff2dc6 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_vmsize_unlimited/74ff2dc6/ulimit_vmsize_unlimited_build.sh
 ulimit_filedescriptor_4096   | c37071b3 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_filedescriptor_4096/c37071b3/ulimit_filedescriptor_4096_build.sh
 ulimit_max_user_process_2048 | 28118dbe | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_max_user_process_2048/28118dbe/ulimit_max_user_process_2048_build.sh
 systemd_default_target       | 9061f933 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/systemd-default-target/systemd_default_target/9061f933/systemd_default_target_build.sh
 ssh_localhost_remotecommand  | ce0e5732 | script | generic.local.bash | ['ssh']                   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ssh_localhost/ssh_localhost_remotecommand/ce0e5732/ssh_localhost_remotecommand_build.sh
 kernel_swapusage             | 18c8b2a2 | script | generic.local.bash | ['configuration']         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/kernel_state/kernel_swapusage/18c8b2a2/kernel_swapusage_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                         | id       | executor           | status   |   returncode
------------------------------+----------+--------------------+----------+--------------
 root_disk_usage              | 3ea2bacf | generic.local.bash | PASS     |            0
 ulimit_filelock_unlimited    | 6f5a22d8 | generic.local.bash | PASS     |            0
 ulimit_cputime_unlimited     | ff97e86d | generic.local.bash | PASS     |            0
 ulimit_stacksize_unlimited   | 0e951b96 | generic.local.bash | FAIL     |            0
 ulimit_vmsize_unlimited      | 74ff2dc6 | generic.local.bash | PASS     |            0
 ulimit_filedescriptor_4096   | c37071b3 | generic.local.bash | FAIL     |            0
 ulimit_max_user_process_2048 | 28118dbe | generic.local.bash | FAIL     |            0
 systemd_default_target       | 9061f933 | generic.local.bash | FAIL     |            1
 ssh_localhost_remotecommand  | ce0e5732 | generic.local.bash | FAIL     |          255
 kernel_swapusage             | 18c8b2a2 | generic.local.bash | FAIL     |          127

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 4/10 Percentage: 40.000%
Failed Tests: 6/10 Percentage: 60.000%


Writing Logfile to: /tmp/buildtest_7ramcqlx.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Building Multiple Buildspecs

You can append -b option to build multiple buildspecs in the same command. Buildtest will discover buildspecs for every argument (-b) and accumulate a list of buildspecs to run. In this example, we instruct buildtest to build a buildspec file and all buildspecs in a directory path.

$ buildtest build -b general_tests/configuration/ -b tutorials/vars.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:44
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b general_tests/configuration/ -b tutorials/vars.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                               |
+=====================================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml             |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml           |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml                |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml                                     |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml          |
+-------------------------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  6
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  6

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml



name                          description
----------------------------  ----------------------------------------------------------------
systemd_default_target        check if default target is multi-user.target
root_disk_usage               Check root disk usage and report if it exceeds threshold
kernel_swapusage              Retrieve Kernel Swap Usage
ulimit_filelock_unlimited     Check if file lock is set to unlimited in ulimits
ulimit_cputime_unlimited      Check if cputime is set to unlimited in ulimits
ulimit_stacksize_unlimited    Check if stack size is set to unlimited in ulimits
ulimit_vmsize_unlimited       Check virtual memory size and check if its set to unlimited
ulimit_filedescriptor_4096    Check if open file descriptors limit is set to 4096
ulimit_max_user_process_2048  Check max number of user process limit is set to 2048
variables_bash                Declare shell variables in bash
ssh_localhost_remotecommand   Test if ssh on localhost works and if we can run remote command.

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                         | id       | type   | executor           | tags                      | testpath
------------------------------+----------+--------+--------------------+---------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 systemd_default_target       | 5ccc431b | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/systemd-default-target/systemd_default_target/5ccc431b/systemd_default_target_build.sh
 root_disk_usage              | 7492c276 | script | generic.local.bash | ['filesystem', 'storage'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/disk_usage/root_disk_usage/7492c276/root_disk_usage_build.sh
 kernel_swapusage             | 168713a5 | script | generic.local.bash | ['configuration']         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/kernel_state/kernel_swapusage/168713a5/kernel_swapusage_build.sh
 ulimit_filelock_unlimited    | 9b348bb5 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_filelock_unlimited/9b348bb5/ulimit_filelock_unlimited_build.sh
 ulimit_cputime_unlimited     | 2e5a5e58 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_cputime_unlimited/2e5a5e58/ulimit_cputime_unlimited_build.sh
 ulimit_stacksize_unlimited   | de1f6873 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_stacksize_unlimited/de1f6873/ulimit_stacksize_unlimited_build.sh
 ulimit_vmsize_unlimited      | 2d9bc797 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_vmsize_unlimited/2d9bc797/ulimit_vmsize_unlimited_build.sh
 ulimit_filedescriptor_4096   | 6f0b9f41 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_filedescriptor_4096/6f0b9f41/ulimit_filedescriptor_4096_build.sh
 ulimit_max_user_process_2048 | 7fc52728 | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ulimits/ulimit_max_user_process_2048/7fc52728/ulimit_max_user_process_2048_build.sh
 variables_bash               | 223864f7 | script | generic.local.bash | ['tutorials']             | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/vars/variables_bash/223864f7/variables_bash_build.sh
 ssh_localhost_remotecommand  | ce350fe9 | script | generic.local.bash | ['ssh']                   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ssh_localhost/ssh_localhost_remotecommand/ce350fe9/ssh_localhost_remotecommand_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                         | id       | executor           | status   |   returncode
------------------------------+----------+--------------------+----------+--------------
 systemd_default_target       | 5ccc431b | generic.local.bash | FAIL     |            1
 root_disk_usage              | 7492c276 | generic.local.bash | PASS     |            0
 kernel_swapusage             | 168713a5 | generic.local.bash | FAIL     |          127
 ulimit_filelock_unlimited    | 9b348bb5 | generic.local.bash | PASS     |            0
 ulimit_cputime_unlimited     | 2e5a5e58 | generic.local.bash | PASS     |            0
 ulimit_stacksize_unlimited   | de1f6873 | generic.local.bash | FAIL     |            0
 ulimit_vmsize_unlimited      | 2d9bc797 | generic.local.bash | PASS     |            0
 ulimit_filedescriptor_4096   | 6f0b9f41 | generic.local.bash | FAIL     |            0
 ulimit_max_user_process_2048 | 7fc52728 | generic.local.bash | FAIL     |            0
 variables_bash               | 223864f7 | generic.local.bash | PASS     |            0
 ssh_localhost_remotecommand  | ce350fe9 | generic.local.bash | FAIL     |          255

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 5/11 Percentage: 45.455%
Failed Tests: 6/11 Percentage: 54.545%


Writing Logfile to: /tmp/buildtest_c80lh443.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Excluding Buildspecs

So far we learned how to build buildspecs by file and directory path using the -b option. Next, we will discuss how one may exclude buildspecs which behaves similar to -b option. You can exclude buildspecs via --exclude or short option -x which can be useful when you want to exclude certain files or sub directory.

For example we can build all buildspecs in tutorials but exclude file tutorials/vars.yml by running:

$ buildtest build -b tutorials -x tutorials/vars.yml

buildtest will discover all buildspecs and then exclude any buildspecs specified by -x option. You can specify -x multiple times just like -b option.

For example, we can undo discovery by passing same option to -b and -x as follows

$ buildtest build -b tutorials/ -x tutorials/


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:44
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/ -x tutorials/
There are no Buildspec files to process.

Buildtest will stop immediately if there are no Buildspecs to process, this is true if you were to specify files instead of directory.

In this example, we build all buildspecs in a directory but exclude a file. Buildtest will report the excluded buildspecs in the output and -x option can be appended multiple times. The -x can be a file or a directory and behaves similar to -b option.

$ buildtest build -b general_tests/configuration/ -x general_tests/configuration/ulimits.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:45
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b general_tests/configuration/ -x general_tests/configuration/ulimits.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                               |
+=====================================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml          |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml             |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml                |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml           |
+-------------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml |
+-------------------------------------------------------------------------------------------------------------------------------------+
+----------------------------------------------------------------------------------------------------------------------+
| Excluded Buildspecs                                                                                                  |
+======================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ulimits.yml |
+----------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  5
Excluded Buildspecs:  1
Detected Buildspecs after exclusion:  4

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/ssh_localhost.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/disk_usage.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/kernel_state.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/general_tests/configuration/systemd-default-target.yml



name                         description
---------------------------  ----------------------------------------------------------------
ssh_localhost_remotecommand  Test if ssh on localhost works and if we can run remote command.
root_disk_usage              Check root disk usage and report if it exceeds threshold
kernel_swapusage             Retrieve Kernel Swap Usage
systemd_default_target       check if default target is multi-user.target

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                        | id       | type   | executor           | tags                      | testpath
-----------------------------+----------+--------+--------------------+---------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 ssh_localhost_remotecommand | c5e27d66 | script | generic.local.bash | ['ssh']                   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/ssh_localhost/ssh_localhost_remotecommand/c5e27d66/ssh_localhost_remotecommand_build.sh
 root_disk_usage             | 0b5ef78e | script | generic.local.bash | ['filesystem', 'storage'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/disk_usage/root_disk_usage/0b5ef78e/root_disk_usage_build.sh
 kernel_swapusage            | e0458d95 | script | generic.local.bash | ['configuration']         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/kernel_state/kernel_swapusage/e0458d95/kernel_swapusage_build.sh
 systemd_default_target      | 185f833c | script | generic.local.bash | ['system']                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/systemd-default-target/systemd_default_target/185f833c/systemd_default_target_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                        | id       | executor           | status   |   returncode
-----------------------------+----------+--------------------+----------+--------------
 ssh_localhost_remotecommand | c5e27d66 | generic.local.bash | FAIL     |          255
 root_disk_usage             | 0b5ef78e | generic.local.bash | PASS     |            0
 kernel_swapusage            | e0458d95 | generic.local.bash | FAIL     |          127
 systemd_default_target      | 185f833c | generic.local.bash | FAIL     |            1

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 1/4 Percentage: 25.000%
Failed Tests: 3/4 Percentage: 75.000%


Writing Logfile to: /tmp/buildtest_2vpes2bw.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Building By Tags

buildtest can perform builds by tags by using --tags or short option (-t). In order to use this feature, buildtest must load buildspecs in cache which can be run via buildtest buildspec find. If you are unsure of the available tags you can run buildtest buildspec find --tags or let buildtest tab-complete the available tags. For more details see Querying buildspec tags.

Let’s assume you want to build by tag name network, buildtest will attempt to find all tests that contain tags: ['network'] in the buildspec which is loaded in the buildcache cache. If a test matches the tag name, the test will be picked up during the discover process.

$ buildtest build -t network


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:45
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -t network

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+---------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                   |
+=========================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml |
+---------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

BREAKDOWN OF BUILDSPECS BY TAGS
----------------------------------
Detected Tag Names: ['network']
+---------------------------------------------------------------------------------------------------------+
| network                                                                                                 |
+=========================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml |
+---------------------------------------------------------------------------------------------------------+



+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+---------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml



name                  description
--------------------  -----------------------------
string_tag            tags can be a string
list_of_strings_tags  tags can be a list of strings

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                 | id       | type   | executor           | tags                | testpath
----------------------+----------+--------+--------------------+---------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 string_tag           | 61e3ee4c | script | generic.local.bash | network             | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/tags_example/string_tag/61e3ee4c/string_tag_build.sh
 list_of_strings_tags | b497ac17 | script | generic.local.bash | ['network', 'ping'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/tags_example/list_of_strings_tags/b497ac17/list_of_strings_tags_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                 | id       | executor           | status   |   returncode
----------------------+----------+--------------------+----------+--------------
 string_tag           | 61e3ee4c | generic.local.bash | PASS     |            0
 list_of_strings_tags | b497ac17 | generic.local.bash | FAIL     |          127

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 1/2 Percentage: 50.000%
Failed Tests: 1/2 Percentage: 50.000%


Writing Logfile to: /tmp/buildtest__mqxs2b9.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

You can build by multiple tags by specifying --tags multiple times. In next example we build all tests with tag name pass and python.

$ buildtest build -t python -t pass


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:45
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -t python -t pass

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                      |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml    |
+------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml    |
+------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  3
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  3

BREAKDOWN OF BUILDSPECS BY TAGS
----------------------------------
Detected Tag Names: ['python', 'pass']
+---------------------------------------------------------------------------------------------------------+
| python                                                                                                  |
+=========================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml |
+---------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml |
+---------------------------------------------------------------------------------------------------------+


+------------------------------------------------------------------------------------------------------------+
| pass                                                                                                       |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+



+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml



name                      description
------------------------  ---------------------------------------------------
circle_area               Calculate circle of area given a radius
python_hello              Hello World python
exit1_fail                exit 1 by default is FAIL
exit1_pass                report exit 1 as PASS
returncode_list_mismatch  exit 2 failed since it failed to match returncode 1
returncode_int_match      exit 128 matches returncode 128

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                     | id       | type   | executor             | tags                    | testpath
--------------------------+----------+--------+----------------------+-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 circle_area              | 0b6ab2ac | script | generic.local.python | ['tutorials', 'python'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/python-shell/circle_area/0b6ab2ac/circle_area_build.sh
 python_hello             | 75d6ff53 | script | generic.local.bash   | python                  | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/python-hello/python_hello/75d6ff53/python_hello_build.sh
 exit1_fail               | d2d34e26 | script | generic.local.sh     | ['tutorials', 'fail']   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_fail/d2d34e26/exit1_fail_build.sh
 exit1_pass               | f150bc31 | script | generic.local.sh     | ['tutorials', 'pass']   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_pass/f150bc31/exit1_pass_build.sh
 returncode_list_mismatch | 504a0b7b | script | generic.local.sh     | ['tutorials', 'fail']   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_list_mismatch/504a0b7b/returncode_list_mismatch_build.sh
 returncode_int_match     | cd33b94f | script | generic.local.sh     | ['tutorials', 'pass']   | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_int_match/cd33b94f/returncode_int_match_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                     | id       | executor             | status   |   returncode
--------------------------+----------+----------------------+----------+--------------
 circle_area              | 0b6ab2ac | generic.local.python | PASS     |            0
 python_hello             | 75d6ff53 | generic.local.bash   | PASS     |            0
 exit1_fail               | d2d34e26 | generic.local.sh     | FAIL     |            1
 exit1_pass               | f150bc31 | generic.local.sh     | PASS     |            1
 returncode_list_mismatch | 504a0b7b | generic.local.sh     | FAIL     |            2
 returncode_int_match     | cd33b94f | generic.local.sh     | PASS     |          128

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 4/6 Percentage: 66.667%
Failed Tests: 2/6 Percentage: 33.333%


Writing Logfile to: /tmp/buildtest_5dxqutqv.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

When multiple tags are specified, we search each tag independently and if it’s found in the buildspec cache we retrieve the buildspec file and add file to queue. This queue is a list of buildspecs that buildtest will process (i.e parse, build, run). You can query tags from buildspecs cache to see all available tags by running buildtest buildspec find --tags.

Note

The --tags is used for discovering buildspec file and not filtering tests by tag.

You can combine --tags with --buildspec to discover buildspecs in a single command. buildtest will query tags and buildspecs independently and combine all discovered buildspecs together.

$ buildtest build --tags pass --buildspec tutorials/python-hello.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:46
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build --tags pass --buildspec tutorials/python-hello.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                      |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml    |
+------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  2
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  2

BREAKDOWN OF BUILDSPECS BY TAGS
----------------------------------
Detected Tag Names: ['pass']
+------------------------------------------------------------------------------------------------------------+
| pass                                                                                                       |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+



+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml



name                      description
------------------------  ---------------------------------------------------
python_hello              Hello World python
exit1_fail                exit 1 by default is FAIL
exit1_pass                report exit 1 as PASS
returncode_list_mismatch  exit 2 failed since it failed to match returncode 1
returncode_int_match      exit 128 matches returncode 128

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                     | id       | type   | executor           | tags                  | testpath
--------------------------+----------+--------+--------------------+-----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 python_hello             | 3af45be7 | script | generic.local.bash | python                | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/python-hello/python_hello/3af45be7/python_hello_build.sh
 exit1_fail               | 91fe0aaf | script | generic.local.sh   | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_fail/91fe0aaf/exit1_fail_build.sh
 exit1_pass               | e9a8bc57 | script | generic.local.sh   | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_pass/e9a8bc57/exit1_pass_build.sh
 returncode_list_mismatch | c5e18c4a | script | generic.local.sh   | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_list_mismatch/c5e18c4a/returncode_list_mismatch_build.sh
 returncode_int_match     | 057c3071 | script | generic.local.sh   | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_int_match/057c3071/returncode_int_match_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                     | id       | executor           | status   |   returncode
--------------------------+----------+--------------------+----------+--------------
 python_hello             | 3af45be7 | generic.local.bash | PASS     |            0
 exit1_fail               | 91fe0aaf | generic.local.sh   | FAIL     |            1
 exit1_pass               | e9a8bc57 | generic.local.sh   | PASS     |            1
 returncode_list_mismatch | c5e18c4a | generic.local.sh   | FAIL     |            2
 returncode_int_match     | 057c3071 | generic.local.sh   | PASS     |          128

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 3/5 Percentage: 60.000%
Failed Tests: 2/5 Percentage: 40.000%


Writing Logfile to: /tmp/buildtest_mcl96yu0.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

As you may see, there are several ways to build buildspecs with buildtest. Tags is great way to build a whole collection of tests if you don’t know path to all the files. You can specify multiple tags per buildspecs to classify how test can be run.

Building by Executors

Every buildspec is associated to an executor which is responsible for running the test. You can instruct buildtest to run all tests by given executor via --executor option or short option -e. For instance, if you want to build all test associated to executor generic.local.python you can run:

$ buildtest build --executor generic.local.python

buildtest will query buildspec cache for the executor name and retrieve a list of buildspecs with matching executor name. To see a list of available executors in buildspec cache see querying buildspec executor.

Note

By default all tests are run in buildspec file. The buildtest build --executor option discovers buildspecs if one of the test matches the executor name. The --executor option is not filtering on test level like --filter-tags option.

In this example we run all tests that are associated to generic.local.python executor.

$ buildtest build --executor generic.local.python


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:46
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build --executor generic.local.python

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+--------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                        |
+==============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml |
+--------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml      |
+--------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  2
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  2

BREAKDOWN OF BUILDSPECS BY EXECUTORS
--------------------------------------
Detected Executor Names: ['generic.local.python']
+--------------------------------------------------------------------------------------------------------------+
| generic.local.python                                                                                         |
+==============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml |
+--------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml      |
+--------------------------------------------------------------------------------------------------------------+


[run_only_platform_darwin][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml]: test is skipped because this test is expected to run on platform: Darwin but detected platform: Linux.

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+--------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml



name                     description
-----------------------  ---------------------------------------------------
run_only_platform_linux  This test will only run if target platform is Linux
circle_area              Calculate circle of area given a radius

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                    | id       | type   | executor             | tags                    | testpath
-------------------------+----------+--------+----------------------+-------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 run_only_platform_linux | 49a2b0c0 | script | generic.local.python | ['tutorials']           | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/run_only_platform/run_only_platform_linux/49a2b0c0/run_only_platform_linux_build.sh
 circle_area             | c8374cbd | script | generic.local.python | ['tutorials', 'python'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/python-shell/circle_area/c8374cbd/circle_area_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                    | id       | executor             | status   |   returncode
-------------------------+----------+----------------------+----------+--------------
 run_only_platform_linux | 49a2b0c0 | generic.local.python | PASS     |            0
 circle_area             | c8374cbd | generic.local.python | PASS     |            0

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 2/2 Percentage: 100.000%
Failed Tests: 0/2 Percentage: 0.000%


Writing Logfile to: /tmp/buildtest_qy1lygwq.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Note

The --executor option can be appended to discover tests by multiple executors.

Filtering Buildspecs

buildtest has support for filtering buildspecs based on certain attributes defined in buildspec file. Upon Discover Buildspecs, buildtest will filter out tests or entire buildspec files. The buildtest build --filter option can be used to filter buildspecs which expects a single key=value pair. Currently, buildtest can filter tests based on tags, type and maintainers.

To see all available filter fields you can run buildtest build --helpfilter and buildtest will report the fields followed by description.

$ buildtest build --helpfilter
Field        Description
-----------  ----------------------------------
tags         Filter tests by 'tag' field
type         Filter test by 'type' field
maintainers  Filter test by 'maintainers' field

In this example, we will discover all buildspecs based on tagname pass and then filter each test by tagname pass specified by –filter tags=pass.

$ buildtest build -t pass --filter tags=pass


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:47
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -t pass --filter tags=pass

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                      |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

BREAKDOWN OF BUILDSPECS BY TAGS
----------------------------------
Detected Tag Names: ['pass']
+------------------------------------------------------------------------------------------------------------+
| pass                                                                                                       |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+


[exit1_fail][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in tag filter list: {'tags': 'pass'}
[returncode_list_mismatch][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in tag filter list: {'tags': 'pass'}

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml



name                  description
--------------------  -------------------------------
exit1_pass            report exit 1 as PASS
returncode_int_match  exit 128 matches returncode 128

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                 | id       | type   | executor         | tags                  | testpath
----------------------+----------+--------+------------------+-----------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 exit1_pass           | a0c6f68f | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_pass/a0c6f68f/exit1_pass_build.sh
 returncode_int_match | 0a5db1fe | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_int_match/0a5db1fe/returncode_int_match_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                 | id       | executor         | status   |   returncode
----------------------+----------+------------------+----------+--------------
 exit1_pass           | a0c6f68f | generic.local.sh | PASS     |            1
 returncode_int_match | 0a5db1fe | generic.local.sh | PASS     |          128

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 2/2 Percentage: 100.000%
Failed Tests: 0/2 Percentage: 0.000%


Writing Logfile to: /tmp/buildtest_f08238td.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

buildtest can run filter tests by maintainers, this can be useful if you want to run tests that you are maintainer. The maintainers field is set per buildspec and not each test. You can filter maintiners via --filter maintainers=<MAINTAINER_NAME>. If the maintainers field is not specified the buildspec will be filtered out if --filter maintainers is specified. In this next example, we will build all tests for maintainer @shahzebsiddiqui.

$ buildtest build -b tutorials --filter maintainers=@shahzebsiddiqui


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:47
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials --filter maintainers=@shahzebsiddiqui

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+---------------------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                           |
+=================================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/pre_post_cmds.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_tags.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml                           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_manifest.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml                              |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_multiple_executor_sbatch.yml |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml                      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml                                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/burstbuffer_datawarp_executors.yml       |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/concretize_m4.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml                              |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml                            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml                        |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml                    |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml                                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_install.yml                    |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml             |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test_specs.yml               |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml                      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_directory.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_sbatch.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml               |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/hello_world.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/install_zlib.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/mirror_example.yml                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml                       |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/remove_environment_example.yml     |
+---------------------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  52
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  52


Buildspecs that failed validation
________________________________________________________________________________
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_tags.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_multiple_executor_sbatch.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/burstbuffer_datawarp_executors.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_install.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml

Buildspecs that were filtered out
________________________________________________________________________________
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/pre_post_cmds.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_manifest.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/concretize_m4.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test_specs.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_directory.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_sbatch.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/install_zlib.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/mirror_example.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/remove_environment_example.yml

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile                | validstate   | buildspec
---------------------------+--------------+-----------------------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/pre_post_cmds.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_manifest.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/concretize_m4.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test_specs.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_directory.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_sbatch.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/hello_world.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/install_zlib.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/mirror_example.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/remove_environment_example.yml



name         description
-----------  -------------------
hello_world  hello world example

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name        | id       | type   | executor           | tags      | testpath
-------------+----------+--------+--------------------+-----------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------
 hello_world | 9d31b492 | script | generic.local.bash | tutorials | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/hello_world/hello_world/9d31b492/hello_world_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name        | id       | executor           | status   |   returncode
-------------+----------+--------------------+----------+--------------
 hello_world | 9d31b492 | generic.local.bash | PASS     |            0

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 1/1 Percentage: 100.000%
Failed Tests: 0/1 Percentage: 0.000%


Writing Logfile to: /tmp/buildtest_lfpditjy.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

Please see Query Maintainers on list of maintainers and breakdown of buildspecs by maintainers.

We can also filter tests by type field in the buildspec which corresponds to the schema type. In this next example, we filter all tests by spack schema type by passing option --filter type=spack. We inform buildtest to stop after build stage (--stage=build) for more details see Configure Build Stages.

$ buildtest build -b tutorials --filter type=spack --stage=build


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:48
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials --filter type=spack --stage=build

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+---------------------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                           |
+=================================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml                           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml                        |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/concretize_m4.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/mirror_example.yml                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml                              |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml                                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml             |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_tags.yml                         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/remove_environment_example.yml     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_install.yml                    |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/install_zlib.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/hello_world.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_multiple_executor_sbatch.yml |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_sbatch.yml                   |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml               |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml                          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml                    |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml          |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml                      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_directory.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/burstbuffer_datawarp_executors.yml       |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml                              |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml                |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml                     |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml                                 |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml                       |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test_specs.yml               |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_manifest.yml            |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml         |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/pre_post_cmds.yml                  |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml                      |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml           |
+---------------------------------------------------------------------------------------------------------------------------------+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml                            |
+---------------------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  52
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  52
[status_regex_pass][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml]: test is skipped because it is not in type filter list: spack
[status_regex_fail][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml]: test is skipped because it is not in type filter list: spack
[csh_shell][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml]: test is skipped because it is not in type filter list: spack
[bash_env_variables][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml]: test is skipped because it is not in type filter list: spack
[csh_env_declaration][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml]: test is skipped because it is not in type filter list: spack
[tcsh_env_declaration][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml]: test is skipped because it is not in type filter list: spack
[skip](/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml): test is skipped.
[unskipped][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml]: test is skipped because it is not in type filter list: spack
[python_hello][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml]: test is skipped because it is not in type filter list: spack
[executors_vars_env_declaration][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml]: test is skipped because it is not in type filter list: spack
[metric_regex_example][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml]: test is skipped because it is not in type filter list: spack
[metric_variable_assignment][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml]: test is skipped because it is not in type filter list: spack
[selinux_disable][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml]: test is skipped because it is not in type filter list: spack
[sleep][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml]: test is skipped because it is not in type filter list: spack
[timelimit_min_max][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml]: test is skipped because it is not in type filter list: spack
[timelimit_min][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml]: test is skipped because it is not in type filter list: spack
[timelimit_max][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml]: test is skipped because it is not in type filter list: spack
[timelimit_min_fail][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml]: test is skipped because it is not in type filter list: spack
[timelimit_max_fail][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml]: test is skipped because it is not in type filter list: spack
[metrics_variable_compiler][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml]: test is skipped because it is not in type filter list: spack
[string_tag][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml]: test is skipped because it is not in type filter list: spack
[list_of_strings_tags][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml]: test is skipped because it is not in type filter list: spack
[override_environmentvars][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml]: test is skipped because it is not in type filter list: spack
[circle_area][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml]: test is skipped because it is not in type filter list: spack
[foo_bar][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml]: test is skipped because it is not in type filter list: spack
[default_status_regex][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml]: test is skipped because it is not in type filter list: spack
[override_status_regex][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml]: test is skipped because it is not in type filter list: spack
[hello_world][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/hello_world.yml]: test is skipped because it is not in type filter list: spack
[executor_regex_script_schema][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml]: test is skipped because it is not in type filter list: spack
[openmp_hello_c_example][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml]: test is skipped because it is not in type filter list: spack
[add_numbers][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml]: test is skipped because it is not in type filter list: spack
[custom_run_by_compilers][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml]: test is skipped because it is not in type filter list: spack
[run_only_platform_darwin][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml]: test is skipped because it is not in type filter list: spack
[run_only_platform_linux][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml]: test is skipped because it is not in type filter list: spack
[hello_f][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml]: test is skipped because it is not in type filter list: spack
[exit1_fail][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in type filter list: spack
[exit1_pass][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in type filter list: spack
[returncode_list_mismatch][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in type filter list: spack
[returncode_int_match][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml]: test is skipped because it is not in type filter list: spack
[bash_login_shebang][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml]: test is skipped because it is not in type filter list: spack
[bash_nonlogin_shebang][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml]: test is skipped because it is not in type filter list: spack
[hello_c][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml]: test is skipped because it is not in type filter list: spack
[vecadd_gnu][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml]: test is skipped because it is not in type filter list: spack
[executors_sbatch_declaration][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml]: test is skipped because it is not in type filter list: spack
[status_returncode_by_executors][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml]: test is skipped because it is not in type filter list: spack
[variables_bash][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml]: test is skipped because it is not in type filter list: spack
[_bin_sh_shell][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml]: test is skipped because it is not in type filter list: spack
[_bin_bash_shell][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml]: test is skipped because it is not in type filter list: spack
[bash_shell][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml]: test is skipped because it is not in type filter list: spack
[sh_shell][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml]: test is skipped because it is not in type filter list: spack
[shell_options][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml]: test is skipped because it is not in type filter list: spack
[pre_post_build_run][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml]: test is skipped because it is not in type filter list: spack
[run_only_macos_distro][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml]: test is skipped because it is not in type filter list: spack
[run_only_linux_distro][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml]: test is skipped because it is not in type filter list: spack
[vecadd_gnu_exclude][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml]: test is skipped because it is not in type filter list: spack
[run_only_as_root][/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml]: test is skipped because it is not in type filter list: spack


Buildspecs that failed validation
________________________________________________________________________________
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_tags.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_install.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_multiple_executor_sbatch.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/burstbuffer_datawarp_executors.yml
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile                | validstate   | buildspec
---------------------------+--------------+-----------------------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/status_regex.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/csh_shell_examples.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/environment.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/skip_tests.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-hello.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/multiple_executors.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_regex.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/concretize_m4.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/mirror_example.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/metrics_variable.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/selinux.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/sleep.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/runtime_status_test.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/metrics_openmp.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/tags_example.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/envvar_override.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/maintainers_example.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/remove_environment_example.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/install_zlib.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_status_regex.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/hello_world.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_sbatch.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/executor_regex_script.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/openmp_hello.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/add_numbers.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/custom_run.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_platform.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_fortran.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_directory.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shebang.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/gnu_hello_c.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/vecadd.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/executor_scheduler.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/script/status_by_executors.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/shell_examples.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/spack_test_specs.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/env_create_manifest.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/pre_post_build_run.yml
 spack-v1.0.schema.json    | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/spack/pre_post_cmds.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/run_only_distro.yml
 compiler-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/compilers/compiler_exclude.yml
 script-v1.0.schema.json   | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/root_user.yml



name                              description
--------------------------------  ------------------------------------------------------------------------
spack_test                        Install bzip2 and run spack test and report results
concretize_m4_in_spack_env        Concretize m4 in a spack environment named m4
add_mirror                        Declare spack mirror
add_mirror_in_spack_env           Declare spack mirror in spack environment
remove_environment_automatically  remove spack environment automatically before creating a new environment
remove_environment_explicit       remove spack environment explicitly using the 'rm' property
install_zlib                      Install zlib
spack_sbatch_example              sbatch directives can be defined in spack schema
spack_env_directory               Concretize m4 in a spack environment named m4
spack_test_results_specs_format   Run spack test results with spec format
spack_env_create_from_manifest    Create spack environment from spack.yaml
run_pre_post_commands             Install zlib

+----------------------+
| Stage: Building Test |
+----------------------+ 



 name                             | id       | type   | executor         | tags      | testpath
----------------------------------+----------+--------+------------------+-----------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 spack_test                       | f7335039 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/spack_test/spack_test/f7335039/spack_test_build.sh
 concretize_m4_in_spack_env       | d94a6e65 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/concretize_m4/concretize_m4_in_spack_env/d94a6e65/concretize_m4_in_spack_env_build.sh
 add_mirror                       | 90524672 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/mirror_example/add_mirror/90524672/add_mirror_build.sh
 add_mirror_in_spack_env          | afceb91d | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/mirror_example/add_mirror_in_spack_env/afceb91d/add_mirror_in_spack_env_build.sh
 remove_environment_automatically | 0d42b09d | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/remove_environment_example/remove_environment_automatically/0d42b09d/remove_environment_automatically_build.sh
 remove_environment_explicit      | 0d62285b | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/remove_environment_example/remove_environment_explicit/0d62285b/remove_environment_explicit_build.sh
 install_zlib                     | 4fc5b05a | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/install_zlib/install_zlib/4fc5b05a/install_zlib_build.sh
 spack_sbatch_example             | 49355ed6 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/spack_sbatch/spack_sbatch_example/49355ed6/spack_sbatch_example_build.sh
 spack_env_directory              | 8cc5ab5c | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/env_create_directory/spack_env_directory/8cc5ab5c/spack_env_directory_build.sh
 spack_test_results_specs_format  | 81698401 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/spack_test_specs/spack_test_results_specs_format/81698401/spack_test_results_specs_format_build.sh
 spack_env_create_from_manifest   | 43d62843 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/env_create_manifest/spack_env_create_from_manifest/43d62843/spack_env_create_from_manifest_build.sh
 run_pre_post_commands            | e5639368 | spack  | generic.local.sh | ['spack'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pre_post_cmds/run_pre_post_commands/e5639368/run_pre_post_commands_build.sh

Discover Buildspecs

Now, let’s discuss how buildtest discovers buildspecs since there are several ways to build buildspecs.

The buildspec search resolution is described as follows:

  • If file or directory specified by -b option doesn’t exist we exit immediately.

  • If buildspec path is a directory, traverse directory recursively to find all .yml extensions

  • If buildspec path is a file, check if file extension is not .yml, exit immediately

  • If user specifies --tags or --executor we search in buildspec cache to discover buildspecs.

Shown below is a diagram on how buildtest discovers buildspecs. The user can build buildspecs by --buildspec, –tags, or –executor which will discover the buildspecs. You can exclude buildspecs using --exclude option which is processed after discovering buildspecs. The excluded buildspecs are removed from list if found and final list of buildspecs is processed.

../_images/DiscoverBuildspecs.jpg

Configure Build Stages

We can control behavior of buildtest build command to stop at certain phase using --stage option. The –stage option accepts parse or build, which will instruct buildtest to stop at parse or build phase of the pipeline.

Buildtest will validate all the buildspecs in the parse stage, so you can instruct buildtest to stop at parse stage via --stage=parse. This can be useful when debugging buildspecs that are invalid. In this example below, we instruct buildtest to stop after parse stage.

$ buildtest build -b tutorials/vars.yml --stage=parse


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:49
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/vars.yml --stage=parse

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                           |
+=================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml |
+-------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml



name            description
--------------  -------------------------------
variables_bash  Declare shell variables in bash

Likewise, if you want to troubleshoot your test script without running them you can use --stage=build which will stop after build phase. This can be used when you are writing buildspec to troubleshoot how test is generated. In this next example, we inform buildtest to stop after build stage.

$ buildtest build -b tutorials/vars.yml --stage=build


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:49
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/vars.yml --stage=build

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                           |
+=================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml |
+-------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+-------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/vars.yml



name            description
--------------  -------------------------------
variables_bash  Declare shell variables in bash

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name           | id       | type   | executor           | tags          | testpath
----------------+----------+--------+--------------------+---------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------
 variables_bash | 60fe63ed | script | generic.local.bash | ['tutorials'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.bash/vars/variables_bash/60fe63ed/variables_bash_build.sh

Invalid Buildspecs

buildtest will skip any buildspecs that fail to validate, in that case the test script will not be generated. Here is an example where we have an invalid buildspec.

$ buildtest build -b tutorials/invalid_buildspec_section.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:49
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/invalid_buildspec_section.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+----------------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                                |
+======================================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml |
+----------------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1


Buildspecs that failed validation
________________________________________________________________________________
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_buildspec_section.yml
No buildspecs to process because there are no valid buildspecs

buildtest may skip tests from running if buildspec specifies an invalid executor name since buildtest needs to know this in order to delegate test to Executor class responsible for running the test. Here is an example where test failed to run since we provided invalid executor.

$ buildtest build -b tutorials/invalid_executor.yml


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:49
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/invalid_executor.yml

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+-------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                       |
+=============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml |
+-------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1


Buildspecs that failed validation
________________________________________________________________________________
/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/invalid_executor.yml
No buildspecs to process because there are no valid buildspecs

Rebuild Tests

buildtest can rebuild tests using the --rebuild option which can be useful if you want to test a particular test multiple times. The rebuild option works across all discovered buildspecs and create a new test instance (unique id) and test directory path. To demonstrate we will build tutorials/python-shell.yml three times using --rebuild=3.

$ buildtest build -b tutorials/python-shell.yml --rebuild=3


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:50
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -b tutorials/python-shell.yml --rebuild=3

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+---------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                   |
+=========================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml |
+---------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+---------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/python-shell.yml



name         description
-----------  ---------------------------------------
circle_area  Calculate circle of area given a radius
circle_area  Calculate circle of area given a radius
circle_area  Calculate circle of area given a radius

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name        | id       | type   | executor             | tags                    | testpath
-------------+----------+--------+----------------------+-------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------
 circle_area | a1ef3290 | script | generic.local.python | ['tutorials', 'python'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/python-shell/circle_area/a1ef3290/circle_area_build.sh
 circle_area | 45c0e965 | script | generic.local.python | ['tutorials', 'python'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/python-shell/circle_area/45c0e965/circle_area_build.sh
 circle_area | 9b255d3f | script | generic.local.python | ['tutorials', 'python'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.python/python-shell/circle_area/9b255d3f/circle_area_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name        | id       | executor             | status   |   returncode
-------------+----------+----------------------+----------+--------------
 circle_area | a1ef3290 | generic.local.python | PASS     |            0
 circle_area | 45c0e965 | generic.local.python | PASS     |            0
 circle_area | 9b255d3f | generic.local.python | PASS     |            0

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 3/3 Percentage: 100.000%
Failed Tests: 0/3 Percentage: 0.000%


Writing Logfile to: /tmp/buildtest_dq1msjjf.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

The rebuild works with all options including: --buildspec, --exclude, --tags and --executors. buildtest will perform rebuild for all discovered tests, for instance in this next example we will discover all tests by tag name fail and each test is rebuild twice.

$ buildtest build -t fail --rebuild 2


User:  docs
Hostname:  build-14488818-project-280831-buildtest
Platform:  Linux
Current Time:  2021/08/16 22:11:50
buildtest path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest
buildtest version:  0.10.2
python path: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/envs/v0.10.2/bin/python
python version:  3.6.12
Test Directory:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests
Configuration File:  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/settings/config.yml
Command: /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest build -t fail --rebuild 2

+-------------------------------+
| Stage: Discovering Buildspecs |
+-------------------------------+ 

+------------------------------------------------------------------------------------------------------------+
| Discovered Buildspecs                                                                                      |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+
Discovered Buildspecs:  1
Excluded Buildspecs:  0
Detected Buildspecs after exclusion:  1

BREAKDOWN OF BUILDSPECS BY TAGS
----------------------------------
Detected Tag Names: ['fail']
+------------------------------------------------------------------------------------------------------------+
| fail                                                                                                       |
+============================================================================================================+
| /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml |
+------------------------------------------------------------------------------------------------------------+



+---------------------------+
| Stage: Parsing Buildspecs |
+---------------------------+ 

 schemafile              | validstate   | buildspec
-------------------------+--------------+------------------------------------------------------------------------------------------------------------
 script-v1.0.schema.json | True         | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/tutorials/pass_returncode.yml



name                      description
------------------------  ---------------------------------------------------
exit1_fail                exit 1 by default is FAIL
exit1_pass                report exit 1 as PASS
returncode_list_mismatch  exit 2 failed since it failed to match returncode 1
returncode_int_match      exit 128 matches returncode 128
exit1_fail                exit 1 by default is FAIL
exit1_pass                report exit 1 as PASS
returncode_list_mismatch  exit 2 failed since it failed to match returncode 1
returncode_int_match      exit 128 matches returncode 128

+----------------------+
| Stage: Building Test |
+----------------------+ 

 name                     | id       | type   | executor         | tags                  | testpath
--------------------------+----------+--------+------------------+-----------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 exit1_fail               | 5544d8dc | script | generic.local.sh | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_fail/5544d8dc/exit1_fail_build.sh
 exit1_pass               | 1e4c9d01 | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_pass/1e4c9d01/exit1_pass_build.sh
 returncode_list_mismatch | 0dc69200 | script | generic.local.sh | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_list_mismatch/0dc69200/returncode_list_mismatch_build.sh
 returncode_int_match     | 242ef5b9 | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_int_match/242ef5b9/returncode_int_match_build.sh
 exit1_fail               | 65bfeef1 | script | generic.local.sh | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_fail/65bfeef1/exit1_fail_build.sh
 exit1_pass               | ae27ef4a | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/exit1_pass/ae27ef4a/exit1_pass_build.sh
 returncode_list_mismatch | bb66d1f5 | script | generic.local.sh | ['tutorials', 'fail'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_list_mismatch/bb66d1f5/returncode_list_mismatch_build.sh
 returncode_int_match     | 2dfb02cd | script | generic.local.sh | ['tutorials', 'pass'] | /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/var/tests/generic.local.sh/pass_returncode/returncode_int_match/2dfb02cd/returncode_int_match_build.sh





+---------------------+
| Stage: Running Test |
+---------------------+ 

 name                     | id       | executor         | status   |   returncode
--------------------------+----------+------------------+----------+--------------
 exit1_fail               | 5544d8dc | generic.local.sh | FAIL     |            1
 exit1_pass               | 1e4c9d01 | generic.local.sh | PASS     |            1
 returncode_list_mismatch | 0dc69200 | generic.local.sh | FAIL     |            2
 returncode_int_match     | 242ef5b9 | generic.local.sh | PASS     |          128
 exit1_fail               | 65bfeef1 | generic.local.sh | FAIL     |            1
 exit1_pass               | ae27ef4a | generic.local.sh | PASS     |            1
 returncode_list_mismatch | bb66d1f5 | generic.local.sh | FAIL     |            2
 returncode_int_match     | 2dfb02cd | generic.local.sh | PASS     |          128

+----------------------+
| Stage: Test Summary  |
+----------------------+ 
    
Passed Tests: 4/8 Percentage: 50.000%
Failed Tests: 4/8 Percentage: 50.000%


Writing Logfile to: /tmp/buildtest_mz19a625.log
A copy of logfile can be found at $BUILDTEST_ROOT/buildtest.log -  /home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest.log

The rebuild option expects a range between 1-50, the --rebuild=1 is equivalent to running without --rebuild option. We set a max limit for rebuild option to avoid system degredation due to high workload.

If you try to exceed this bound you will get an error such as

$ buildtest build -b tutorials/pass_returncode.yml --rebuild 51
Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/bin/buildtest", line 17, in <module>
    buildtest.main.main()
  File "/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/main.py", line 99, in main
    helpfilter=args.helpfilter,
  File "/home/docs/checkouts/readthedocs.org/user_builds/buildtest/checkouts/v0.10.2/buildtest/cli/build.py", line 489, in __init__
    f"--rebuild {rebuild} exceeds maximum rebuild limit of 50"
buildtest.exceptions.BuildTestError: '--rebuild 51 exceeds maximum rebuild limit of 50'

Use Alternate Configuration file

If you want to use an alternate configuration file when building test you can use buildtest -c <config> build. buildtest will prefer configuration file on command line over the user configuration ($HOME/.buildtest/config.yml). For more details see Which configuration file does buildtest read?.

Keeping Stage Directory

buildtest will create setup the test environment in the stage directory where test will be executed. Once test is complete, buildtest will remove the stage directory. If you want to preserve the stage directory you can use buildtest build --keep-stage-dir, this is only useful if you want to run the test manually