How to test the value of a variable from info log

Maybe something like

logs, value = Test.collect_test_logs() do
    foo()
end
sym, val = collect(pairs(logs[1].kwargs))[1]
@test sym ≡ :s && occursin(r"world", val)

It would be great to have more of this functionality documented/exported.

2 Likes