vendredi 6 septembre 2019

TestCafe: how to set a button component on a page to a pressed state where its a click but not released?

Im creating an automated test to test the different specs or attributes of an element (button component) but in order to do this I have to force the button to specific states like - pressed and disabled states. I have already done it for the focus and hover states.

  1. how to set a button element/component on a page to a pressed state where the button is clicked but not released - similar to a keydown? Asking since the specs (Text color and background color) of a clicked state and a pressed state are different.

  2. how to set a button element/component on a page to a disabled state.

  3. Is it even possible to force element state similar to inspect/dev tools using the browser?

thanks

Aucun commentaire:

Enregistrer un commentaire