addRule(new AriaRoledescription());
$violations = $scanner->scan('
');
$this->assertCount(1, $violations);
$this->assertSame('WCAG_4_1_2_ARIA_ROLEDESCRIPTION', $violations[0]->ruleId);
}
public function testFlagsRoledescriptionOnPresentation(): void
{
$scanner = new Scanner();
$scanner->addRule(new AriaRoledescription());
$violations = $scanner->scan('');
$this->assertCount(1, $violations);
}
public function testPassesValidRoledescription(): void
{
$scanner = new Scanner();
$scanner->addRule(new AriaRoledescription());
$violations = $scanner->scan('');
$this->assertCount(0, $violations);
}
}