Skip to content

Commit 6ad8294

Browse files
authored
Merge pull request #2105 from CliMA/tr/fix-ci-downgrade-tests
Tr/fix ci downstream tests
2 parents 340603b + 3756754 commit 6ad8294

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

.github/workflows/Downstream.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -46,20 +46,16 @@ jobs:
4646
repository: 'CliMA/${{ matrix.package }}'
4747
path: ${{ matrix.package }}
4848

49-
# The test suite for ClimaTimesteppers depends on ClimaCore, not
50-
# ClimaTimesteppers itself. If we dev-ed ClimaCore in ClimaTimesteppers,
51-
# the aqua test would fail because we never use ClimaCore.
52-
- if: (matrix.package != 'ClimaTimesteppers.jl' && matrix.package != 'ClimaCoupler.jl')
49+
# Some of the packages only use ClimaCore in the test suite, so dev-ing ClimaCore
50+
# from the package itself would cause the aqua test to fail. Instead, we install
51+
# TestEnv into the base environment, activate the test env for the downstream package,
52+
# and dev ClimaCore before running the test suite from there.
53+
- if: (matrix.package != 'ClimaCoupler.jl')
5354
run: |
55+
julia --color=yes -e 'using Pkg; Pkg.add("TestEnv")'
5456
julia --color=yes --project=${{ matrix.package }} -e 'using Pkg; Pkg.instantiate()'
55-
julia --color=yes --project=${{ matrix.package }} -e 'using Pkg; Pkg.develop(; path = ".")'
56-
julia --color=yes --project=${{ matrix.package }} -e 'using Pkg; Pkg.test()'
57-
58-
- if: matrix.package == 'ClimaTimesteppers.jl'
59-
run: |
60-
julia --color=yes --project=ClimaTimesteppers.jl/test -e 'using Pkg; Pkg.instantiate()'
61-
julia --color=yes --project=ClimaTimesteppers.jl/test -e 'using Pkg; Pkg.develop(; path = ".")'
62-
julia --color=yes --project=ClimaTimesteppers.jl/test ClimaTimesteppers.jl/test/runtests.jl
57+
julia --color=yes --project=${{ matrix.package }} -e 'using TestEnv; TestEnv.activate();\
58+
using Pkg; Pkg.develop(; path = "."); include("${{ matrix.package }}/test/runtests.jl")'
6359
6460
- if: matrix.package == 'ClimaCoupler.jl'
6561
run: |

0 commit comments

Comments
 (0)