Skip to content

Commit 81e1658

Browse files
Merge pull request #150 from sharanry/sy/downstream_ci
Add downstream tests
2 parents e6fed29 + bdec019 commit 81e1658

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed

.github/workflows/Downstream.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: IntegrationTest
2+
on:
3+
push:
4+
branches: [master]
5+
tags: [v*]
6+
pull_request:
7+
8+
jobs:
9+
test:
10+
name: ${{ matrix.package.repo }}/${{ matrix.package.group }}
11+
runs-on: ${{ matrix.os }}
12+
env:
13+
GROUP: ${{ matrix.package.group }}
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
julia-version: [1]
18+
os: [ubuntu-latest]
19+
package:
20+
- {user: SciML, repo: SciMLBase.jl, group: Core}
21+
- {user: SciML, repo: DiffEqBase.jl, group: Core}
22+
- {user: SciML, repo: DiffEqBase.jl, group: Downstream}
23+
- {user: SciML, repo: DiffEqSensitivity.jl, group: Core}
24+
- {user: SciML, repo: OrdinaryDiffEq.jl, group: Core}
25+
- {user: SciML, repo: OrdinaryDiffEq.jl, group: Interface}
26+
- {user: SciML, repo: DelayDiffEq.jl, group: Interface}
27+
steps:
28+
- uses: actions/checkout@v2
29+
- uses: julia-actions/setup-julia@v1
30+
with:
31+
version: ${{ matrix.julia-version }}
32+
arch: x64
33+
- uses: julia-actions/julia-buildpkg@latest
34+
- name: Clone Downstream
35+
uses: actions/checkout@v2
36+
with:
37+
repository: ${{ matrix.package.user }}/${{ matrix.package.repo }}
38+
path: downstream
39+
- name: Load this and run the downstream tests
40+
shell: julia --color=yes --project=downstream {0}
41+
run: |
42+
using Pkg
43+
try
44+
# force it to use this PR's version of the package
45+
Pkg.develop(PackageSpec(path=".")) # resolver may fail with main deps
46+
Pkg.update()
47+
Pkg.test() # resolver may fail with test time deps
48+
catch err
49+
err isa Pkg.Resolve.ResolverError || rethrow()
50+
# If we can't resolve that means this is incompatible by SemVer and this is fine
51+
# It means we marked this as a breaking change, so we don't need to worry about
52+
# Mistakenly introducing a breaking change, as we have intentionally made one
53+
@info "Not compatible with this release. No problem." exception=err
54+
exit(0) # Exit immediately, as a success
55+
end

0 commit comments

Comments
 (0)