Skip to content

Commit 675f8e0

Browse files
authored
Add breakage CI (#258)
* Add MRIBase breakage tests * Add MRIOperators breakage test
1 parent e6b2df6 commit 675f8e0

3 files changed

Lines changed: 79 additions & 2 deletions

File tree

.github/workflows/ci_mribase.yml

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,4 +63,44 @@ jobs:
6363
with:
6464
file: lcov.info
6565
token: ${{ secrets.CODECOV_TOKEN }}
66-
flags: MRIBase
66+
flags: MRIBase
67+
68+
# Based on https://github.com/SciML/OrdinaryDiffEq.jl/blob/master/.github/workflows/Downstream.yml
69+
breakage:
70+
name: Breakage ${{ matrix.package }} (Julia ${{ matrix.julia-version}})
71+
runs-on: ${{ matrix.os }}
72+
strategy:
73+
fail-fast: false
74+
matrix:
75+
julia-version:
76+
- '1.10'
77+
os:
78+
- ubuntu-latest
79+
package:
80+
- MRIOperators
81+
- MRISimulation
82+
- MRICoilSensitivities
83+
- MRISampling
84+
- MRIFiles
85+
- MRIReco
86+
steps:
87+
- uses: actions/checkout@v4
88+
- uses: julia-actions/setup-julia@v2
89+
with:
90+
version: ${{ matrix.julia-version }}
91+
arch: x64
92+
- name: Test Breakage ${{ matrix.package }}
93+
env:
94+
BREAK_PKG: ${{ matrix.package }}
95+
shell: julia --color=yes {0}
96+
run: |
97+
using Pkg
98+
try
99+
Pkg.add(ENV["BREAK_PKG"]) # Add for release version
100+
Pkg.develop([PackageSpec(path=pwd(), subdir="MRIBase")])
101+
Pkg.test(ENV["BREAK_PKG"], coverage=true) # resolver may fail with test time depsAdd commentMore actions
102+
catch err
103+
err isa Pkg.Resolve.ResolverError || rethrow()
104+
@info "Not compatible with this release. No need to check for breakage" exception=err
105+
exit(0)
106+
end

.github/workflows/ci_mrioperators.yml

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,4 +67,40 @@ jobs:
6767
with:
6868
file: lcov.info
6969
token: ${{ secrets.CODECOV_TOKEN }}
70-
flags: MRIOperators
70+
flags: MRIOperators
71+
72+
# Based on https://github.com/SciML/OrdinaryDiffEq.jl/blob/master/.github/workflows/Downstream.yml
73+
breakage:
74+
name: Breakage ${{ matrix.package }} (Julia ${{ matrix.julia-version}})
75+
runs-on: ${{ matrix.os }}
76+
strategy:
77+
fail-fast: false
78+
matrix:
79+
julia-version:
80+
- '1.10'
81+
os:
82+
- ubuntu-latest
83+
package:
84+
- MRISimulation
85+
- MRIReco
86+
steps:
87+
- uses: actions/checkout@v4
88+
- uses: julia-actions/setup-julia@v2
89+
with:
90+
version: ${{ matrix.julia-version }}
91+
arch: x64
92+
- name: Test Breakage ${{ matrix.package }}
93+
env:
94+
BREAK_PKG: ${{ matrix.package }}
95+
shell: julia --color=yes {0}
96+
run: |
97+
using Pkg
98+
try
99+
Pkg.add(ENV["BREAK_PKG"]) # Add for release version
100+
Pkg.develop([PackageSpec(path=pwd(), subdir="MRIOperators")])
101+
Pkg.test(ENV["BREAK_PKG"], coverage=true) # resolver may fail with test time depsAdd commentMore actions
102+
catch err
103+
err isa Pkg.Resolve.ResolverError || rethrow()
104+
@info "Not compatible with this release. No need to check for breakage" exception=err
105+
exit(0)
106+
end

MRIBase/src/MRIBase.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ module MRIBase
33
using AbstractNFFTs
44
using NFFTTools # for density compensation weights in trajectory
55

6+
67
include("Trajectories/Trajectories.jl")
78
include("Datatypes/Datatypes.jl")
89
include("Datatypes/Flags.jl")

0 commit comments

Comments
 (0)