forked from mom-ocean/MOM6
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
49 lines (41 loc) · 1.54 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# This Travis-CI file is for testing the state of the MOM6 source code.
# It does NOT test MOM6 solutions.
# This is a not a c-language project but we use the same environment.
language: c
dist: trusty
sudo: false
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- tcsh pkg-config netcdf-bin libnetcdf-dev openmpi-bin libopenmpi-dev gfortran
# For saving time...
cache:
directories:
- MOM6-examples
- build
# Install tools and clone the configurations repository
before_install:
- git clone https://github.com/adcroft/house_cleaning.git
# This line clones MOM6-examples when there is no cache
- test -f MOM6-examples/README.md || (rm -rf MOM6-examples && git clone https://github.com/NOAA-GFDL/MOM6-examples.git)
install:
# This restores all files in MOM6-examples and updates
- (cd MOM6-examples/ && git checkout . && git pull)
# Update submodules mkmf and FMS
- (cd MOM6-examples/src/ && git submodule init mkmf FMS && git submodule update mkmf FMS)
# Build FMS
before_script:
- bash MOM6-examples/tools/tests/Travis-MOM6/build_fms.sh
- bash MOM6-examples/tools/tests/Travis-MOM6/before_script.sh
# Tests to run
script:
- ./house_cleaning/trailer.py -e TEOS10 src config_src
- bash MOM6-examples/tools/tests/Travis-MOM6/build_ocean_only.sh
- bash MOM6-examples/tools/tests/Travis-MOM6/build_symmetric_ocean_only.sh
- bash MOM6-examples/tools/tests/Travis-MOM6/run_tests.sh
before_cache:
- rm -rf build/ocn build/symocn
- (cd MOM6-examples; rm -rf ocean_only; git checkout .)
- find MOM6-examples -type l -exec rm {} \;