Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.

Commit 0d593de

Browse files
non-allocating on v1.7+
ugh v1.6 is now getting old lol
1 parent 2cae4ff commit 0d593de

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

test/basictests.jl

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ sol = benchmark_scalar(sf, csu0)
2222
@test sol.retcode === ReturnCode.Success
2323
@test sol.u * sol.u - 2 < 1e-9
2424

25-
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
25+
if VERSION >= v"1.7"
26+
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
27+
end
2628

2729
# Broyden
2830
function benchmark_scalar(f, u0)
@@ -33,7 +35,9 @@ end
3335
sol = benchmark_scalar(sf, csu0)
3436
@test sol.retcode === ReturnCode.Success
3537
@test sol.u * sol.u - 2 < 1e-9
36-
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
38+
if VERSION >= v"1.7"
39+
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
40+
end
3741

3842
# Klement
3943
function benchmark_scalar(f, u0)
@@ -44,7 +48,9 @@ end
4448
sol = benchmark_scalar(sf, csu0)
4549
@test sol.retcode === ReturnCode.Success
4650
@test sol.u * sol.u - 2 < 1e-9
47-
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
51+
if VERSION >= v"1.7"
52+
@test (@ballocated benchmark_scalar(sf, csu0)) == 0
53+
end
4854

4955
# TrustRegion
5056
function benchmark_scalar(f, u0)

0 commit comments

Comments
 (0)