i have custom buttons (SVG's with click handlers) which i want to ensure are disabled under certain circumstances. Since these elements have disabled styling I've been using the aria-disabled
attrubtue for this purpose (two birds one stone)
so i would like to be able to test asexpect(myCustomSvgButton).toBeDisabled()
obiviously this is doable just now using .toHaveAttribute
but i feel like this reduces the clarity of what's being checked and focuses on implementation details making the test brittle.
on a side note, maybe encouraging the use of aria-*
attrs for communication of more complex state in the DOM is not a bad thing?
gnapse, alexkrolick, Replayattack, hibearpanda, sanchopancho13 and 13 moreggorlen
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4