Skip to content

Commit cc93129

Browse files
committed
test: more test fixes
1 parent 088d65c commit cc93129

File tree

5 files changed

+9
-8
lines changed

5 files changed

+9
-8
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ LeastSquaresOptim = "0.8.5"
8181
LineSearches = "7.2"
8282
LinearAlgebra = "1.10"
8383
LinearSolve = "2.30"
84-
MINPACK = "=1.2"
84+
MINPACK = "1.2"
8585
MaybeInplace = "0.1.3"
8686
ModelingToolkit = "9.15.0"
8787
NLSolvers = "0.5"

lib/SciMLJacobianOperators/src/SciMLJacobianOperators.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,8 @@ function JacobianOperator(prob::AbstractNonlinearProblem, fu, u; jvp_autodiff =
117117
vjp_op = prepare_vjp(skip_vjp, prob, f, u, fu; autodiff = vjp_autodiff)
118118
jvp_op = prepare_jvp(skip_jvp, prob, f, u, fu; autodiff = jvp_autodiff)
119119

120-
output_cache = similar(fu, T)
121-
input_cache = similar(u, T)
120+
output_cache = fu isa Number ? T(fu) : similar(fu, T)
121+
input_cache = u isa Number ? T(u) : similar(u, T)
122122

123123
return JacobianOperator{iip, T}(
124124
JVP(), jvp_op, vjp_op, (length(fu), length(u)), output_cache, input_cache)

src/NonlinearSolve.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ using Preferences: Preferences, @load_preference, @set_preferences!
4040
using RecursiveArrayTools: recursivecopy!, recursivefill!
4141
using SciMLBase: AbstractNonlinearAlgorithm, JacobianWrapper, AbstractNonlinearProblem,
4242
AbstractSciMLOperator, _unwrap_val, has_jac, isinplace, NLStats
43-
using SciMLJacobianOperators: JacobianOperator, VecJacOperator, JacVecOperator,
44-
StatefulJacobianOperator
43+
using SciMLJacobianOperators: AbstractJacobianOperator, JacobianOperator, VecJacOperator,
44+
JacVecOperator, StatefulJacobianOperator
4545
using SparseArrays: AbstractSparseMatrix, SparseMatrixCSC
4646
using SparseDiffTools: SparseDiffTools, AbstractSparsityDetection,
4747
ApproximateJacobianSparsity, JacPrototypeSparsityDetection,

src/utils.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ end
4848
return deepcopy(x)
4949
end
5050
@inline __maybe_unaliased(x::AbstractNonlinearSolveOperator, alias::Bool) = x
51+
@inline __maybe_unaliased(x::AbstractJacobianOperator, alias::Bool) = x
5152

5253
@inline __cond(J::AbstractMatrix) = cond(J)
5354
@inline __cond(J::SVector) = __cond(Diagonal(MVector(J)))

test/runtests.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ const RETESTITEMS_NWORKER_THREADS = parse(Int,
1010
get(ENV, "RETESTITEMS_NWORKER_THREADS",
1111
string(max(Hwloc.num_virtual_cores() ÷ RETESTITEMS_NWORKERS, 1))))
1212

13-
@info "Running tests for group: $LUXLIB_TEST_GROUP with $RETESTITEMS_NWORKERS workers"
13+
@info "Running tests for group: $(GROUP) with $(RETESTITEMS_NWORKERS) workers"
1414

1515
ReTestItems.runtests(NonlinearSolve; tags = (GROUP == "all" ? nothing : [Symbol(GROUP)]),
16-
nworkers = RETESTITEMS_NWORKERS,
17-
nworker_threads = RETESTITEMS_NWORKER_THREADS, testitem_timeout = 3600, retries=4)
16+
nworkers = RETESTITEMS_NWORKERS, nworker_threads = RETESTITEMS_NWORKER_THREADS,
17+
testitem_timeout = 3600, retries = 4)

0 commit comments

Comments
 (0)