Skip to content

Commit

Permalink
Automated doc updates (#515)
Browse files Browse the repository at this point in the history
* Automated doc updates on Perlmutter

* Automated doc updates on Compy

* Automated doc updates on Chrysalis
  • Loading branch information
forsyth2 authored Sep 26, 2023
1 parent 67d5dbc commit dadaadc
Show file tree
Hide file tree
Showing 3 changed files with 135 additions and 9 deletions.
48 changes: 45 additions & 3 deletions tests/integration/generated/directions_chrysalis.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,23 @@ rm -rf /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_bund
rm -rf /lcrc/group/e3sm/ac.forsyth2/zppy_test_bundles_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run first set of jobs:
zppy -c tests/integration/generated/test_bundles_chrysalis.cfg
# bundle1 and bundle2 should run. After they finish, invoke zppy again to resolve remaining dependencies:
# bundle1 and bundle2 should run. After they finish, check the results:
cd /lcrc/group/e3sm/ac.forsyth2/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# Now, invoke zppy again to run jobs that needed to wait for dependencies:
zppy -c tests/integration/generated/test_bundles_chrysalis.cfg
# bundle3 and ilamb should run
# bundle3 and ilamb should run. After they finish, check the results:
cd /lcrc/group/e3sm/ac.forsyth2/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles expected_bundles_v<version>
```

### test_complete_run
Expand All @@ -22,7 +35,16 @@ rm -rf /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_comp
rm -rf /lcrc/group/e3sm/ac.forsyth2/zppy_test_complete_run_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run jobs:
zppy -c tests/integration/generated/test_complete_run_chrysalis.cfg
# After they finish, check the results:
cd /lcrc/group/e3sm/ac.forsyth2/zppy_test_complete_run_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /lcrc/group/e3sm/public_html/zppy_test_resources/expected_complete_run expected_complete_run_v<version>
```

## Commands to run to replace outdated expected files
Expand All @@ -39,7 +61,7 @@ mv test_bash_generation_output/post/scripts /lcrc/group/e3sm/public_html/zppy_te
python -u -m unittest tests/integration/test_bash_generation.py
```

#### test_bundles
### test_bundles

```
rm -rf /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles
Expand All @@ -49,6 +71,8 @@ cp -r /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_bundl
mkdir -p /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles/bundle_files
cp -r /lcrc/group/e3sm/ac.forsyth2/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles/bundle_files
cd /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/forsyth/zppy_test_bundles_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_bundles.txt
cd <top level of zppy repo>
Expand Down Expand Up @@ -79,6 +103,8 @@ rm -rf /lcrc/group/e3sm/public_html/zppy_test_resources/expected_complete_run
# Copy output so you don't have to rerun zppy to generate the output.
cp -r /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_complete_run_www/v2.LR.historical_0201 /lcrc/group/e3sm/public_html/zppy_test_resources/expected_complete_run
cd /lcrc/group/e3sm/public_html/zppy_test_resources/expected_complete_run
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/forsyth/zppy_test_complete_run_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_complete_run.txt
cd <top level of zppy repo>
Expand All @@ -97,3 +123,19 @@ mv test_defaults_output/post/scripts/*.settings /lcrc/group/e3sm/public_html/zpp
# Rerun test
python -u -m unittest tests/integration/test_defaults.py
```

## Commands to generate official expected results for a release

### test_bundles

```
cp -r /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_bundles_www/v2.LR.historical_0201 /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles_unified_<#>
mkdir -p /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
cp -r /lcrc/group/e3sm/ac.forsyth2/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /lcrc/group/e3sm/public_html/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
```

### test_complete_run

```
cp -r /lcrc/group/e3sm/public_html/diagnostic_output/ac.forsyth2/zppy_test_complete_run_www/v2.LR.historical_0201 /lcrc/group/e3sm/public_html/zppy_test_resources/expected_complete_run_unified_<#>
```
48 changes: 45 additions & 3 deletions tests/integration/generated/directions_compy.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,23 @@ rm -rf /compyfs/www/fors729/zppy_test_bundles_www/v2.LR.historical_0201
rm -rf /compyfs/fors729/zppy_test_bundles_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run first set of jobs:
zppy -c tests/integration/generated/test_bundles_compy.cfg
# bundle1 and bundle2 should run. After they finish, invoke zppy again to resolve remaining dependencies:
# bundle1 and bundle2 should run. After they finish, check the results:
cd /compyfs/fors729/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# Now, invoke zppy again to run jobs that needed to wait for dependencies:
zppy -c tests/integration/generated/test_bundles_compy.cfg
# bundle3 and ilamb should run
# bundle3 and ilamb should run. After they finish, check the results:
cd /compyfs/fors729/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /compyfs/www/zppy_test_resources/expected_bundles expected_bundles_v<version>
```

### test_complete_run
Expand All @@ -22,7 +35,16 @@ rm -rf /compyfs/www/fors729/zppy_test_complete_run_www/v2.LR.historical_0201
rm -rf /compyfs/fors729/zppy_test_complete_run_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run jobs:
zppy -c tests/integration/generated/test_complete_run_compy.cfg
# After they finish, check the results:
cd /compyfs/fors729/zppy_test_complete_run_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /compyfs/www/zppy_test_resources/expected_complete_run expected_complete_run_v<version>
```

## Commands to run to replace outdated expected files
Expand All @@ -39,7 +61,7 @@ mv test_bash_generation_output/post/scripts /compyfs/www/zppy_test_resources/exp
python -u -m unittest tests/integration/test_bash_generation.py
```

#### test_bundles
### test_bundles

```
rm -rf /compyfs/www/zppy_test_resources/expected_bundles
Expand All @@ -49,6 +71,8 @@ cp -r /compyfs/www/fors729/zppy_test_bundles_www/v2.LR.historical_0201 /compyfs/
mkdir -p /compyfs/www/zppy_test_resources/expected_bundles/bundle_files
cp -r /compyfs/fors729/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /compyfs/www/zppy_test_resources/expected_bundles/bundle_files
cd /compyfs/www/zppy_test_resources/expected_bundles
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /compyfs/www/fors729/forsyth/zppy_test_bundles_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_bundles.txt
cd <top level of zppy repo>
Expand Down Expand Up @@ -79,6 +103,8 @@ rm -rf /compyfs/www/zppy_test_resources/expected_complete_run
# Copy output so you don't have to rerun zppy to generate the output.
cp -r /compyfs/www/fors729/zppy_test_complete_run_www/v2.LR.historical_0201 /compyfs/www/zppy_test_resources/expected_complete_run
cd /compyfs/www/zppy_test_resources/expected_complete_run
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /compyfs/www/fors729/forsyth/zppy_test_complete_run_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_complete_run.txt
cd <top level of zppy repo>
Expand All @@ -97,3 +123,19 @@ mv test_defaults_output/post/scripts/*.settings /compyfs/www/zppy_test_resources
# Rerun test
python -u -m unittest tests/integration/test_defaults.py
```

## Commands to generate official expected results for a release

### test_bundles

```
cp -r /compyfs/www/fors729/zppy_test_bundles_www/v2.LR.historical_0201 /compyfs/www/zppy_test_resources/expected_bundles_unified_<#>
mkdir -p /compyfs/www/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
cp -r /compyfs/fors729/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /compyfs/www/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
```

### test_complete_run

```
cp -r /compyfs/www/fors729/zppy_test_complete_run_www/v2.LR.historical_0201 /compyfs/www/zppy_test_resources/expected_complete_run_unified_<#>
```
48 changes: 45 additions & 3 deletions tests/integration/generated/directions_pm-cpu.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,23 @@ rm -rf /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_bundles_www/v2.LR.historical
rm -rf /global/cfs/cdirs/e3sm/forsyth/zppy_test_bundles_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run first set of jobs:
zppy -c tests/integration/generated/test_bundles_pm-cpu.cfg
# bundle1 and bundle2 should run. After they finish, invoke zppy again to resolve remaining dependencies:
# bundle1 and bundle2 should run. After they finish, check the results:
cd /global/cfs/cdirs/e3sm/forsyth/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# Now, invoke zppy again to run jobs that needed to wait for dependencies:
zppy -c tests/integration/generated/test_bundles_pm-cpu.cfg
# bundle3 and ilamb should run
# bundle3 and ilamb should run. After they finish, check the results:
cd /global/cfs/cdirs/e3sm/forsyth/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles expected_bundles_v<version>
```

### test_complete_run
Expand All @@ -22,7 +35,16 @@ rm -rf /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_complete_run_www/v2.LR.histo
rm -rf /global/cfs/cdirs/e3sm/forsyth/zppy_test_complete_run_output/v2.LR.historical_0201/post
# Generate cfg
python tests/integration/utils.py
# Run jobs:
zppy -c tests/integration/generated/test_complete_run_pm-cpu.cfg
# After they finish, check the results:
cd /global/cfs/cdirs/e3sm/forsyth/zppy_test_complete_run_output/v2.LR.historical_0201/post/scripts
grep -v "OK" *status
# Nothing should print
# If a final release has just been made, run:
cp /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_complete_run expected_complete_run_v<version>
```

## Commands to run to replace outdated expected files
Expand All @@ -39,7 +61,7 @@ mv test_bash_generation_output/post/scripts /global/cfs/cdirs/e3sm/www/zppy_test
python -u -m unittest tests/integration/test_bash_generation.py
```

#### test_bundles
### test_bundles

```
rm -rf /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles
Expand All @@ -49,6 +71,8 @@ cp -r /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_bundles_www/v2.LR.historical_
mkdir -p /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles/bundle_files
cp -r /global/cfs/cdirs/e3sm/forsyth/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles/bundle_files
cd /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /global/cfs/cdirs/e3sm/www/forsyth/forsyth/zppy_test_bundles_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_bundles.txt
cd <top level of zppy repo>
Expand Down Expand Up @@ -79,6 +103,8 @@ rm -rf /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_complete_run
# Copy output so you don't have to rerun zppy to generate the output.
cp -r /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_complete_run_www/v2.LR.historical_0201 /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_complete_run
cd /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_complete_run
# Remove the image check failures, so they don't end up in the expected files.
rm -rf /global/cfs/cdirs/e3sm/www/forsyth/forsyth/zppy_test_complete_run_www/v2.LR.historical_0201/image_check_failures
# This file will list all the expected images.
find . -type f -name '*.png' > ../image_list_expected_complete_run.txt
cd <top level of zppy repo>
Expand All @@ -97,3 +123,19 @@ mv test_defaults_output/post/scripts/*.settings /global/cfs/cdirs/e3sm/www/zppy_
# Rerun test
python -u -m unittest tests/integration/test_defaults.py
```

## Commands to generate official expected results for a release

### test_bundles

```
cp -r /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_bundles_www/v2.LR.historical_0201 /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles_unified_<#>
mkdir -p /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
cp -r /global/cfs/cdirs/e3sm/forsyth/zppy_test_bundles_output/v2.LR.historical_0201/post/scripts/bundle*.bash /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_bundles_unified_<#>/bundle_files
```

### test_complete_run

```
cp -r /global/cfs/cdirs/e3sm/www/forsyth/zppy_test_complete_run_www/v2.LR.historical_0201 /global/cfs/cdirs/e3sm/www/zppy_test_resources/expected_complete_run_unified_<#>
```

0 comments on commit dadaadc

Please sign in to comment.