I'm currently facing a challenge while writing an end-to-end Protractor test. I need to verify whether a checkbox is enabled or not, but it doesn't have a 'checked' property. Is there a way in JavaScript to iterate through a list, check if an element is checked, and retrieve its corresponding text?
Below is the HTML snippet:
<li>
<div _ngcontent-c8="" class="ng-tns-c8-2" >
<input _ngcontent-c8="" class="ng-tns-c8-2" type="checkbox" id="Team TableAccepted">
<label _ngcontent-c8="" class="ng-tns-c8-2" for="Team TableAccepted">Accepted</label></div>
</li>