Now that we have a PR for Niente, a do-nothing display library that doesn't have a ton of Webview incidental complexity, we can use it for Lacci testing.
I've started by doing a bit of an error cleanup. We want a Shoes::Errors namespace so that the online docs don't look so messy with a ton of random error classes mixed with everything else. We also want a bunch of Scarpe errors that are really in Shoes code to move into Shoes (see issue #440, which this doesn't fix, but helps.)
I also (again) got rid of that annoying backtrace printed to console on every successful run of the promises unit tests -- those started printing the whole backtrace again when I switched the tests to use the simple print logger instead of the complicated configurable logger.
Image(if needed, helps for a faster review)
Not actually an image, but here's what the Niente-based Lacci tests look like now for errors:
def test_drawables_found_errors
run_test_niente_code(<<~SHOES_APP, app_test_code: <<~SHOES_SPEC)
Shoes.app do
button "OK"
button "Not OK"
end
SHOES_APP
assert_raises Shoes::Errors::MultipleDrawablesFoundError do
button()
end
assert_raises Shoes::Errors::NoDrawablesFoundError do
edit_line()
end
SHOES_SPEC
end
Description
Now that we have a PR for Niente, a do-nothing display library that doesn't have a ton of Webview incidental complexity, we can use it for Lacci testing.
I've started by doing a bit of an error cleanup. We want a Shoes::Errors namespace so that the online docs don't look so messy with a ton of random error classes mixed with everything else. We also want a bunch of Scarpe errors that are really in Shoes code to move into Shoes (see issue #440, which this doesn't fix, but helps.)
I also (again) got rid of that annoying backtrace printed to console on every successful run of the promises unit tests -- those started printing the whole backtrace again when I switched the tests to use the simple print logger instead of the complicated configurable logger.
Image(if needed, helps for a faster review)
Not actually an image, but here's what the Niente-based Lacci tests look like now for errors:
Very pretty, I think!
Checklist