Skip to content

Commit 5c6ff0f

Browse files
committed
Fix: Keep code from version checks, only remove conditionals
Since Julia v1.10 is now the LTS, version checks for v1.8 and v1.9 are always true. Keep the code that was inside these checks but remove the conditionals themselves. - Keep FastLAPACK Factorizations testset (was v1.9 gated) - Keep MKLLUFactorization test, only remove VERSION check - Keep test_interface call for prob3/prob4 (was v1.9 gated) - Keep Cholesky solve test (was v1.8 gated) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 6cd3598 commit 5c6ff0f

File tree

2 files changed

+17
-19
lines changed

2 files changed

+17
-19
lines changed

test/basictests.jl

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -198,24 +198,22 @@ end
198198
test_interface(SparspakFactorization(), prob1, prob2)
199199
end
200200

201-
if VERSION >= v"1.9"
202-
@testset "FastLAPACK Factorizations" begin
203-
A1 = A / 1
204-
b1 = rand(n)
205-
x1 = zero(b)
206-
A2 = A / 2
207-
b2 = rand(n)
208-
x2 = zero(b)
201+
@testset "FastLAPACK Factorizations" begin
202+
A1 = A / 1
203+
b1 = rand(n)
204+
x1 = zero(b)
205+
A2 = A / 2
206+
b2 = rand(n)
207+
x2 = zero(b)
209208

210-
prob1 = LinearProblem(A1, b1; u0 = x1)
211-
prob2 = LinearProblem(A2, b2; u0 = x2)
212-
test_interface(LinearSolve.FastLUFactorization(), prob1, prob2)
213-
test_interface(LinearSolve.FastQRFactorization(), prob1, prob2)
209+
prob1 = LinearProblem(A1, b1; u0 = x1)
210+
prob2 = LinearProblem(A2, b2; u0 = x2)
211+
test_interface(LinearSolve.FastLUFactorization(), prob1, prob2)
212+
test_interface(LinearSolve.FastQRFactorization(), prob1, prob2)
214213

215-
# TODO: Resizing tests. Upstream doesn't currently support it.
216-
# Need to be absolutely certain we never segfault with incorrect
217-
# ws sizes.
218-
end
214+
# TODO: Resizing tests. Upstream doesn't currently support it.
215+
# Need to be absolutely certain we never segfault with incorrect
216+
# ws sizes.
219217
end
220218

221219
test_algs = [
@@ -226,15 +224,15 @@ end
226224
LinearSolve.defaultalg(prob1.A, prob1.b)
227225
]
228226

229-
if VERSION >= v"1.9" && LinearSolve.usemkl
227+
if LinearSolve.usemkl
230228
push!(test_algs, MKLLUFactorization())
231229
end
232230

233231
@testset "Concrete Factorizations" begin
234232
for alg in test_algs
235233
@testset "$alg" begin
236234
test_interface(alg, prob1, prob2)
237-
VERSION >= v"1.9" && test_interface(alg, prob3, prob4)
235+
test_interface(alg, prob3, prob4)
238236
end
239237
end
240238
if LinearSolve.appleaccelerate_isavailable()

test/sparse_vector.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ linsolve = init(prob);
4545
H = hess_mat' * hess_mat
4646
prob = LinearProblem(H, hess_mat' * grad_vec)
4747
linsolve = init(prob, CholeskyFactorization())
48-
VERSION >= v"1.8" && @test solve!(linsolve).u H \ Array(hess_mat' * grad_vec)
48+
@test solve!(linsolve).u H \ Array(hess_mat' * grad_vec)
4949

5050
# https://github.com/SciML/LinearSolve.jl/issues/614
5151
A = sprand(ComplexF64, 10, 10, 0.5)

0 commit comments

Comments
 (0)