Skip to content

Commit b2b0d05

Browse files
committed
Appease JuliaFormatter
[skip ci]
1 parent 4bd419c commit b2b0d05

File tree

2 files changed

+19
-13
lines changed

2 files changed

+19
-13
lines changed

test/trim/optimization_trimmable.jl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,11 @@ end
2727

2828
const autodiff = AutoForwardDiff(; chunksize = 1)
2929
const alg = TrustRegion(; autodiff, linsolve = LS.CholeskyFactorization())
30-
const prob = NonlinearLeastSquaresProblem{false}(f, rand(2), MyParams(rand(), hermitianpart(rand(2, 2) + 2I)))
30+
const prob = NonlinearLeastSquaresProblem{false}(
31+
f,
32+
rand(2),
33+
MyParams(rand(), hermitianpart(rand(2, 2) + 2I))
34+
)
3135
const cache = init(prob, alg)
3236

3337
function minimize(x)

test/trim/runtests.jl

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ end
2222

2323
@safetestset "Run trim" begin
2424
# https://discourse.julialang.org/t/capture-stdout-and-stderr-in-case-a-command-fails/101772/3?u=romeov
25-
"Run a Cmd object, returning the stdout & stderr contents plus the exit code"
25+
"""
26+
Run a Cmd object, returning the stdout & stderr contents plus the exit code
27+
"""
2628
function _execute(cmd::Cmd)
2729
out = Pipe()
2830
err = Pipe()
@@ -31,27 +33,27 @@ end
3133
close(err.in)
3234
out = (
3335
stdout = String(read(out)), stderr = String(read(err)),
34-
exitcode = process.exitcode,
36+
exitcode = process.exitcode
3537
)
3638
return out
3739
end
3840

3941
JULIAC = normpath(
4042
joinpath(
41-
Sys.BINDIR, Base.DATAROOTDIR, "julia", "juliac",
42-
"juliac.jl"
43-
)
43+
Sys.BINDIR, Base.DATAROOTDIR, "julia", "juliac",
44+
"juliac.jl"
45+
)
4446
)
4547
@test isfile(JULIAC)
4648

4749
for (mainfile, expectedtopass) in [
48-
("main_trimmable.jl", true),
49-
#= The test below should verify that we indeed can't get a trimmed binary
50-
# for the "clean" implementation, but will trigger in the future if
51-
# it does start working. Unfortunately, right now it hangs indefinitely
52-
# so we are commenting it out. =#
53-
# ("main_clean.jl", false),
54-
]
50+
("main_trimmable.jl", true),
51+
#= The test below should verify that we indeed can't get a trimmed binary
52+
# for the "clean" implementation, but will trigger in the future if
53+
# it does start working. Unfortunately, right now it hangs indefinitely
54+
# so we are commenting it out. =#
55+
# ("main_clean.jl", false),
56+
]
5557
binpath = tempname()
5658
cmd = `$(Base.julia_cmd()) --project=. --depwarn=error $(JULIAC) --experimental --trim=unsafe-warn --output-exe $(binpath) $(mainfile)`
5759

0 commit comments

Comments
 (0)