Skip to content

Commit 63ad8a2

Browse files
committed
Use ballocated
1 parent d45be3c commit 63ad8a2

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

Project.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
1313
UnPack = "3a884ed6-31ef-47d7-9d2a-63182c4928ed"
1414

1515
[extras]
16+
BenchmarkTools = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf"
1617
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
1718

1819
[targets]
19-
test = ["Test"]
20+
test = ["BenchmarkTools", "Test"]

test/runtests.jl

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
using NonlinearSolve
22
using StaticArrays
3+
using BenchmarkTools
34
using Test
45

56
function benchmark_immutable(f, u0)
@@ -28,6 +29,6 @@ sol = benchmark_mutable(f, u0)
2829
sol = benchmark_scalar(sf, su0)
2930
@test sol * sol - 2 < 1e-9
3031

31-
@allocated benchmark_immutable(f, u0)
32-
@allocated benchmark_mutable(f, u0)
33-
@allocated benchmark_scalar(sf, su0)
32+
@test_broken (@ballocated benchmark_immutable($f, $u0)) == 0
33+
@test_broken (@ballocated benchmark_mutable($f, $u0)) == 0
34+
@test (@ballocated benchmark_scalar($sf, $su0)) == 0

0 commit comments

Comments
 (0)