Mox library `verify_on_exit!()` vs. `:verify_on_exit!`

Any ideas why the documentation suggested :verify_on_exit! would fail to verify() anything, while the verify_on_exit!() form would work as expected?

Depends how you have it set up. Can you provide a code snippet?

1 Like

Yes, you prompted me to double-check it and yeah, my bad:

setup :verify_on_exit! differs a lot from:

setup do
    :verify_on_exit!
   // ....
end

which (the latter) doesn’t make much sense :wink: The Fine Manual says:

“Accepts a block or the name of a one-arity function in the form of an atom […]”

2 Likes