Skip to content

Commit 8f6ed8c

Browse files
Merge branch 'mom-ocean:main' into dev/gfdl
2 parents 596b781 + d4d7fbe commit 8f6ed8c

488 files changed

Lines changed: 84677 additions & 43205 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.codecov.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@ coverage:
99
threshold: 100%
1010
base: parent
1111
comment:
12-
# This must be set to the number of test cases (TCs)
13-
after_n_builds: 8
12+
# This is set to the number of TCs, plus unit, but can be removed
13+
# (i.e. set to 1) when reporting is separated from coverage.
14+
after_n_builds: 9
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: 'install-macos-prerequisites'
2+
3+
description: 'Install prerequisites for Mac OS compilation'
4+
5+
runs:
6+
using: 'composite'
7+
8+
steps:
9+
- name: Install macOS packages
10+
shell: bash
11+
run: |
12+
echo "::group::Install packages"
13+
brew update
14+
brew install automake
15+
brew install netcdf
16+
brew install mpich
17+
echo "::endgroup::"
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: 'Build-.testing-prerequisites'
2+
description: 'Build pre-requisites for .testing including FMS and a symmetric MOM6 executable'
3+
inputs:
4+
build_symmetric:
5+
description: 'If true, will build the symmetric MOM6 executable'
6+
required: false
7+
default: 'true'
8+
install_python:
9+
description: 'If true, will install the local python env needed for .testing'
10+
required: false
11+
default: 'true'
12+
runs:
13+
using: 'composite'
14+
steps:
15+
- name: Git info
16+
shell: bash
17+
run: |
18+
echo "::group::Git commit info"
19+
echo "git log:"
20+
git log | head -60
21+
echo "::endgroup::"
22+
23+
- name: Env
24+
shell: bash
25+
run: |
26+
echo "::group::Environment"
27+
env
28+
echo "::endgroup::"
29+
30+
- name: Compile FMS library
31+
shell: bash
32+
run: |
33+
echo "::group::Compile FMS library"
34+
cd .testing
35+
make deps/lib/libFMS.a -s -j
36+
echo "::endgroup::"
37+
38+
- name: Store compiler flags used in Makefile
39+
shell: bash
40+
run: |
41+
echo "::group::config.mk"
42+
cd .testing
43+
echo "FCFLAGS_DEBUG=-g -O0 -Wextra -Wno-compare-reals -fbacktrace -ffpe-trap=invalid,zero,overflow -fcheck=bounds" >> config.mk
44+
echo "FCFLAGS_REPRO=-g -O2 -fbacktrace" >> config.mk
45+
echo "FCFLAGS_INIT=-finit-real=snan -finit-integer=2147483647 -finit-derived" >> config.mk
46+
cat config.mk
47+
echo "::endgroup::"
48+
49+
- name: Compile MOM6 in symmetric memory mode
50+
shell: bash
51+
run: |
52+
echo "::group::Compile MOM6 in symmetric memory mode"
53+
cd .testing
54+
test ${{ inputs.build_symmetric }} == true && make build/symmetric/MOM6 -j
55+
echo "::endgroup::"
56+
57+
- name: Install local python venv for generating input data
58+
shell: bash
59+
run: |
60+
echo "::group::Create local python env for input data generation"
61+
cd .testing
62+
test ${{ inputs.install_python }} == true && make work/local-env
63+
echo "::endgroup::"
64+
65+
- name: Set flags
66+
shell: bash
67+
run: |
68+
echo "TIMEFORMAT=... completed in %lR (user: %lU, sys: %lS)" >> $GITHUB_ENV
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: 'install-ubuntu-prerequisites'
2+
3+
description: 'Install prerequisites for Ubuntu Linux compilation'
4+
5+
runs:
6+
using: 'composite'
7+
steps:
8+
- name: Install Ubuntu Linux packages
9+
shell: bash
10+
run: |
11+
echo "::group::Install linux packages"
12+
sudo apt-get update
13+
sudo apt-get install netcdf-bin
14+
sudo apt-get install libnetcdf-dev
15+
sudo apt-get install libnetcdff-dev
16+
sudo apt-get install mpich
17+
sudo apt-get install libmpich-dev
18+
sudo apt-get install linux-tools-common
19+
echo "::endgroup::"

.github/workflows/coupled-api.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: API for coupled drivers
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-top-api:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/ubuntu-setup
19+
20+
- uses: ./.github/actions/testing-setup
21+
with:
22+
build_symmetric: 'false'
23+
install_python: 'false'
24+
25+
- name: Compile MOM6 for the GFDL coupled driver
26+
shell: bash
27+
run: make check_mom6_api_coupled -j
28+
29+
- name: Compile MOM6 for the NUOPC driver
30+
shell: bash
31+
run: make check_mom6_api_nuopc -j
32+
33+
- name: Compile MOM6 for the MCT driver
34+
shell: bash
35+
run: make check_mom6_api_mct -j

.github/workflows/coverage.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Code coverage
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build-test-nans:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
env:
14+
REPORT_COVERAGE: true
15+
16+
steps:
17+
- uses: actions/checkout@v2
18+
with:
19+
submodules: recursive
20+
21+
- uses: ./.github/actions/ubuntu-setup
22+
23+
- uses: ./.github/actions/testing-setup
24+
25+
- name: Compile unit testing
26+
run: make -j build/unit/MOM6
27+
28+
- name: Run unit tests
29+
run: make unit.cov.upload
30+
31+
- name: Compile MOM6 with code coverage
32+
run: make -j build/cov/MOM6
33+
34+
- name: Run and post coverage
35+
run: make run.cov -k -s
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Doxygen and style
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
doxygen:
7+
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- uses: actions/checkout@v2
12+
with:
13+
submodules: recursive
14+
15+
- name: Check white space (non-blocking)
16+
run: |
17+
./.testing/trailer.py -e TEOS10 -l 120 src config_src 2>&1 | tee style_errors
18+
continue-on-error: true
19+
20+
- name: Install packages used when generating documentation
21+
run: |
22+
sudo apt-get update
23+
sudo apt-get install python3-sphinx python3-lxml perl
24+
sudo apt-get install texlive-binaries texlive-base bibtool tex-common texlive-bibtex-extra
25+
sudo apt-get install graphviz
26+
27+
- name: Build doxygen HTML
28+
run: |
29+
cd docs
30+
perl -e 'print "perl version $^V" . "\n"'
31+
mkdir _build && make nortd DOXYGEN_RELEASE=Release_1_8_13 UPDATEHTMLEQS=Y
32+
cat _build/doxygen_warn_nortd_log.txt
33+
34+
- name: Report doxygen or style errors
35+
run: |
36+
grep "warning:" docs/_build/doxygen_warn_nortd_log.txt | grep -v "as part of a" | tee doxy_errors
37+
cat style_errors doxy_errors > all_errors
38+
cat all_errors
39+
test ! -s all_errors

.github/workflows/expression.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Expression verification
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-repro-and-dims:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/ubuntu-setup
19+
20+
- uses: ./.github/actions/testing-setup
21+
22+
- name: Compile MOM6 using repro optimization
23+
run: make build/repro/MOM6 -j
24+
25+
- name: Create validation data
26+
run: make run.symmetric -k -s
27+
28+
- name: Run tests
29+
run: make test.repro test.dim -k -s
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: MacOS regression
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
test-macos-regression:
7+
8+
runs-on: macOS-latest
9+
10+
env:
11+
CC: gcc-11
12+
FC: gfortran-11
13+
14+
defaults:
15+
run:
16+
working-directory: .testing
17+
18+
steps:
19+
- uses: actions/checkout@v2
20+
with:
21+
submodules: recursive
22+
23+
- uses: ./.github/actions/macos-setup
24+
25+
- uses: ./.github/actions/testing-setup
26+
27+
- name: Compile reference model
28+
run: make build.regressions MOM_TARGET_SLUG=$GITHUB_REPOSITORY MOM_TARGET_LOCAL_BRANCH=$GITHUB_BASE_REF DO_REGRESSION_TESTS=true -j
29+
30+
- name: Create validation data
31+
run: make run.symmetric -k -s
32+
33+
- name: Regression test
34+
run: make test.regression DO_REGRESSION_TESTS=true -k -s
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: MacOS stencil tests
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-macos-stencil:
7+
8+
runs-on: macOS-latest
9+
10+
env:
11+
CC: gcc-11
12+
FC: gfortran-11
13+
14+
defaults:
15+
run:
16+
working-directory: .testing
17+
18+
steps:
19+
- uses: actions/checkout@v2
20+
with:
21+
submodules: recursive
22+
23+
- uses: ./.github/actions/macos-setup
24+
25+
- uses: ./.github/actions/testing-setup
26+
27+
- name: Compile MOM6 in asymmetric memory mode
28+
run: make build/asymmetric/MOM6 -j
29+
30+
- name: Create validation data
31+
run: make run.symmetric -k -s
32+
33+
- name: Run tests
34+
run: make test.grid test.layout test.rotate -k -s

0 commit comments

Comments
 (0)