Skip to content

Commit 53e6e22

Browse files
dpoMaxenceGollier
authored andcommitted
🤖 Format .jl files
1 parent 337245a commit 53e6e22

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

src/AL_alg.jl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,11 @@ mutable struct ALSolver{T, V, M, Pb, ST} <: AbstractOptimizationSolver
148148
sub_stats::GenericExecutionStats{T, V, V, T}
149149
end
150150

151-
function ALSolver(reg_nlp::AbstractRegularizedNLPModel{T, V}; subsolver = R2Solver, kwargs...) where {T, V}
151+
function ALSolver(
152+
reg_nlp::AbstractRegularizedNLPModel{T, V};
153+
subsolver = R2Solver,
154+
kwargs...,
155+
) where {T, V}
152156
nlp = reg_nlp.model
153157
nvar, ncon = nlp.meta.nvar, nlp.meta.ncon
154158
x = V(undef, nvar)

test/test_AL.jl

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,14 @@ problem_list = [:hs8]
1212
@test length(stats.solution) == nlp.meta.nvar
1313
@test typeof(stats.solution) == typeof(nlp.meta.x0)
1414

15-
stats = AL(LBFGSModel(nlp), h, subsolver = R2NSolver, atol = 1e-3, verbose = 1, subsolver_max_iter = 1000)
15+
stats = AL(
16+
LBFGSModel(nlp),
17+
h,
18+
subsolver = R2NSolver,
19+
atol = 1e-3,
20+
verbose = 1,
21+
subsolver_max_iter = 1000,
22+
)
1623
@test stats.status == :first_order
1724
@test stats.primal_feas <= 1e-2
1825
@test stats.dual_feas <= 1e-2

0 commit comments

Comments
 (0)