<commit_before>#OnEarth CI Test Scripts

This directory contains files and scripts to test various aspects of OnEarth. The included tests are:


* `test_mod_onearth.py` -- tests the OnEarth Apache module
* `test_layer_config.py` -- tests the Layer Config tool

##Setup
These tests assume that OnEarth and its associated utilities are installed.

The contents of this directory need to be copied to `/etc/onearth/config`. You'll need to make sure that the `LCDIR` environment variable is properly set.

The tests have additional dependencies from the rest of OnEarth. To install the Python dependencies required by the test scripts, run `sudo pip install -r requirements.txt`.

##Running the tests
Each test script will output a JUnit XML results file. By default, this file is named `test_mod_onearth_results.xml`. A different output filename can be specified with the `-o` option, i.e. `sudo python test_mod_onearth.py -o output_file.xml`.

**Note that the tests need to be run with root privileges.**

*`test_mod_onearth.py` also offers a `-d, --debug` option. This will load the test Apache configuration for manual testing purposes (normally the script deletes it when the tests are over.)*

*`test_layer_config.py` also offers a `-d, --debug` option. This will display verbose messages about the files the script is creating and text it's searching for in the config tool output files.*<commit_msg>README update<commit_after>#OnEarth CI Test Scripts

This directory contains files and scripts to test various aspects of OnEarth. The included tests are:


* `test_mod_onearth.py` -- tests the OnEarth Apache module
* `test_layer_config.py` -- tests the Layer Config tool

##Setup
These tests assume that OnEarth and its associated utilities are installed.

The contents of this directory need to be copied to `/etc/onearth/config`. You'll need to make sure that the `LCDIR` environment variable is properly set.

The tests have additional dependencies from the rest of OnEarth. To install the Python dependencies required by the test scripts, run `sudo pip install -r requirements.txt`.

##Running the tests
Each test script will output a JUnit XML results file. By default, these files are named `test_layer_config_results.xml` and `test_mod_onearth_results.xml`. A different output filename can be specified with the `-o` option, i.e. `sudo python test_mod_onearth.py -o output_file.xml`.

**Note that the tests need to be run with root privileges.**

*`test_mod_onearth.py` also offers a `-d, --debug` option. This will load the test Apache configuration for manual testing purposes (normally the script deletes it when the tests are over.)*

*`test_layer_config.py` also offers a `-d, --debug` option. This will display verbose messages about the files the script is creating and text it's searching for in the config tool output files.*
{'fraction_non_alphanumeric': 0.06572934973637962, 'fraction_numerical': 0.0, 'mean_word_length': 4.569471624266145, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 5}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2313095', 'n_tokens_mistral': 759, 'n_tokens_neox': 730, 'n_words': 402}