elm-html-test
elm-html-test copied to clipboard
Have a way to get the options that the handler for a simulated event set
I am adding functions in avh4/elm-program-test to help verify correct implementation of links in single-page apps. To do this correctly, I need a way to test whether the onClick handler of a found node is setting the preventDefault option.
This could possibly be done by changing toResult to:
toResult : Event msg -> Result String { msg : msg, options : Html.Events.Options }
Or maybe by adding:
getOptions : Event msg -> Result String Html.Events.Options
See: elm-explorations/test#80