Created
July 7, 2016 13:10
-
-
Save chalasr/de05cf6ffb2e93de515b01132fcd00cb to your computer and use it in GitHub Desktop.
Behat context feature: Element with id :id should have attribute :attribute containing :expectedValue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @Then element with id :id should have attribute :attribute containing :expectedValue | |
*/ | |
public function elementWithIdShouldHaveAttributeContaining($id, $attribute, $expectedValue) | |
{ | |
$this->assertSession()->elementAttributeContains('css', '#'.$id, $attribute , $expectedValue); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Usage = Then element with id "pages_2-collapse" should have attribute "aria-expanded" containing "true"