Skip to content

InputDate / InputNumber handling #502

Answered by egil
LordBenjamin asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @LordBenjamin, thanks for a well described issue.

If there is an asynchronous re-render being triggered by Change, then you might need to use WaitForAssertion, since that synchronizes between the render thread and the test thread. Learn more about it here: https://bunit.dev/docs/verification/async-assertion

var deliveryDateField = component.Find("#delivery-date");
deliveryDateField.Change("2021-09-20");

component.WaitForAssertion(() => deliveryDateField.MarkupMatches(@"<input id=""delivery-date"" type=""date"" class=""form-control modified valid"" value=""2021-09-20"" />");

Try this and let me know how it goes.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by egil
Comment options

You must be logged in to vote
1 reply
@egil
Comment options

egil Oct 3, 2021
Maintainer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #496 on October 03, 2021 20:17.