MDL-45320 behat: change to block selector

This commit is contained in:
Marina Glancy 2014-05-20 18:53:06 +08:00
parent deeaed4332
commit f06daff29d

View File

@ -96,11 +96,10 @@ XPATH
normalize-space(descendant::div[@class='hd']) = %locator%]
XPATH
, 'block' => <<<XPATH
//div[contains(concat(' ', normalize-space(@class), ' '), concat(' ', %locator%, ' '))] |
//div[contains(concat(' ', normalize-space(@class), ' '), ' block ')]
/descendant::h2[normalize-space(.) = %locator%]
/ancestor::div[contains(concat(' ', normalize-space(@class), ' '), ' block ')] |
//div[contains(concat(' ', normalize-space(@class), ' '), ' block ')][@aria-label = %locator% ]
//div[contains(concat(' ', normalize-space(@class), ' '), ' block ') and
(contains(concat(' ', normalize-space(@class), ' '), concat(' ', %locator%, ' ')) or
descendant::h2[normalize-space(.) = %locator%] or
@aria-label = %locator%)]
XPATH
, 'region' => <<<XPATH
//*[self::div | self::section | self::aside | self::header | self::footer][./@id = %locator%]