Skip to content

Binding TelerikTextBox value in bUnit test #651

Answered by Gambero81
Gambero81 asked this question in Q&A
Discussion options

You must be logged in to vote

Finally i solved using SetParameterAndRender to reset DebouceDelay for all TelerikTextBox inside the component under test:

protected void ResetTelerikTextBoxDebounceDelay<T>(IRenderedComponent<T> cut) where T : Microsoft.AspNetCore.Components.IComponent
{
    var txtElements = cut.FindComponents<TelerikTextBox>();
    foreach (var txt in txtElements)
        txt.SetParametersAndRender(parameters => parameters.Add(p => p.DebounceDelay, 0));
}

Replies: 12 comments 5 replies

Comment options

linkdotnet
Feb 28, 2022
Maintainer Sponsor

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

linkdotnet
Feb 28, 2022
Maintainer Sponsor

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

linkdotnet
Mar 1, 2022
Maintainer Sponsor

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

Comment options

You must be logged in to vote
0 replies
Comment options

linkdotnet
Mar 7, 2022
Maintainer Sponsor

You must be logged in to vote
0 replies
Comment options

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

linkdotnet Mar 7, 2022
Maintainer Sponsor

Comment options

You must be logged in to vote
3 replies
@linkdotnet
Comment options

linkdotnet Mar 7, 2022
Maintainer Sponsor

@Gambero81
Comment options

@EdCharbeneau
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by Gambero81
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants
Converted from issue

This discussion was converted from issue #647 on March 01, 2022 10:10.