Testing Components without Element ID's RRS feed

  • Question

  • User-2113093675 posted

    It appears that the decision was made to remove ID's (and really, any identifying information) for field inputs from Blazor. How are we supposed to identify individual fields to validate behaviors in both BUnit and other test frameworks like Selenium? Is it expected that the developer is responsible for writing the code to re-add support for ID's or Name attributes to these inputs, or is there a recommended approach I haven't seen yet?

    To be clear, I am aware of the solutions outlined in this article and other similar approaches. This makes things more difficult than simply being able to ID individual elements to validate their values. Is this really the only approach provided?

    Wednesday, January 13, 2021 5:39 PM

All replies