From ad1f745aacae0449056a8c7fb4b4e4e528eb0d11 Mon Sep 17 00:00:00 2001 From: nhz2 Date: Tue, 24 Oct 2023 18:25:00 -0400 Subject: [PATCH] add test of run_sim --- test/test_ref_out.jl | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/test/test_ref_out.jl b/test/test_ref_out.jl index 17e1cbd..0be0ea9 100644 --- a/test/test_ref_out.jl +++ b/test/test_ref_out.jl @@ -93,4 +93,26 @@ end end end end + +@testset "deprecated full run example" begin + test_out = joinpath(@__DIR__, "example/output/deprecated-full") + rm(test_out; force=true, recursive=true) + args = ["--out=$test_out","--batch=1"] + with_logger(warn_only_logger) do + MEDYANSimRunner.run_sim(args; + UserCode.jobs, + UserCode.setup, + save_snapshot=UserCode.save, + load_snapshot=UserCode.load, + UserCode.loop, + UserCode.done, + ) + end + out_diff = sprint(MEDYANSimRunner.print_traj_diff, joinpath(ref_out,"a"), joinpath(test_out,"a")) + if !isempty(out_diff) + println(out_diff) + @test false + end + end +end end \ No newline at end of file