Skip to content

Commit

Permalink
Fix test for saving errors with coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
bennibolm committed Feb 1, 2024
1 parent 5e5fecf commit d4a3e4b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion test/test_tree_2d_euler.jl
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,13 @@ end
output_directory="out")
lines = readlines("out/deviations.txt")
@test lines[1] == "# iter, simu_time, rho_min, rho_max"
@test startswith(lines[end], "1")
cmd = string(Base.julia_cmd())
coverage = occursin("--code-coverage", cmd) &&
!occursin("--code-coverage=none", cmd)
if !coverage
# Run without coverage takes 96 time steps.
@test startswith(lines[end], "96")
end
# Ensure that we do not have excessive memory allocations
# (e.g., from type instabilities)
let
Expand Down

0 comments on commit d4a3e4b

Please sign in to comment.