Blame Readme

Karanbir Singh 43deec
This Git repo contains all the functional tests run for various packages and roles in the CentOS build + release process
Karanbir Singh 43deec
Karanbir Singh 43deec
filesystem layout:
Karanbir Singh 43deec
Karanbir Singh 43deec
tests/         : contains all test scripts
Karanbir Singh 43deec
Karanbir Singh 43deec
tests/0_lib/   : contains all the common functions and shared code for 
Karanbir Singh 43deec
                 the tests all files in that directory are 'sourced' 
Karanbir Singh 43deec
                 before any of the tests are run, which also means it 
Karanbir Singh 43deec
                 can only contain bash code ( no subdir allowed )
Karanbir Singh 43deec
Karanbir Singh 43deec
tests/_common/ : Contain's testst that are run before any other test,
Karanbir Singh 43deec
                 and immediately after the 0_lib/ code is sourced.
Karanbir Singh 43deec
                 These should be tests that check system sanity and 
Karanbir Singh 43deec
                 environment. These tests should also not leave behind
Karanbir Singh 43deec
                 any state or content residue that would impact package
Karanbir Singh 43deec
                 and role specific tests that are run after
Karanbir Singh 43deec
Karanbir Singh 43deec
tests/p_<name>/ : Each of the p_<name> directories would contain tests
Karanbir Singh 43deec
                  for that specific package. The <name> needs to be -
Karanbir Singh 43deec
                  rpm --qf "%{name}\n" for the srpm.
Karanbir Singh 43deec
Karanbir Singh 43deec
                  All package tests are run on a machine which has a minimal
Karanbir Singh 43deec
                  install. Its not possible, at this time, to have a kickstart
Karanbir Singh 43deec
                  attached with the package tests.
Karanbir Singh 43deec
Karanbir Singh 43deec
tests/r_<role>  : Each of the r_<role> directories should contain the tests
Karanbir Singh 43deec
                  specific to a role. eg: 'lamp'. The test harness looks at
Karanbir Singh 43deec
                  a file called 'pacakge_deps' inside each of the role directories
Karanbir Singh 43deec
                  and runs the role tests if any package listed in that file 
Karanbir Singh 43deec
                  has been changed / built etc.
Karanbir Singh 43deec
Karanbir Singh 43deec
                  Role tests can be run with specific kickstarts. At the moment
Karanbir Singh 43deec
                  each role can have 1 kickstart file. It must be called 
Karanbir Singh 43deec
                  ks_<role>.cfg and it must be in the tests/r_<role>/ directory
Karanbir Singh 43deec
    
Karanbir Singh 43deec
notes...
Karanbir Singh 43deec
- each of the directories are parsed in alphabetical order, so its possible
Karanbir Singh 43deec
  to set some sort of a run order by using <number>_<TestName>
Karanbir Singh 43deec
Karanbir Singh 43deec
- if tests are written in any language other than bash, its upto the test
Karanbir Singh 43deec
  to install the required environment ( including python, ruby, perl.. )
Karanbir Singh e86e4c
Karanbir Singh e86e4c
- all files named 'readme', or starting with an underscore are ignored 
Karanbir Singh e86e4c
  by the test harness ( so one can use the _<filename> to host metadata
Karanbir Singh e86e4c
  or any config that might be needed for a test.