Skip to content

Commit 6dd769b

Browse files
authored
Merge pull request #86 from kschroeder/master
Updated the cart summary to wait until the first test element exists.
2 parents 9aab9c8 + 79781c8 commit 6dd769b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/Magento/Extractors/Checkout/CartSummary.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
use Magium\Extractors\AbstractExtractor;
77
use Magium\Magento\Actions\Checkout\Steps\StepInterface;
88
use Magium\Magento\Themes\OnePageCheckout\AbstractThemeConfiguration;
9+
use Magium\WebDriver\ExpectedCondition;
910
use Magium\WebDriver\WebDriver;
1011

1112
class CartSummary extends AbstractExtractor implements StepInterface
@@ -70,6 +71,7 @@ public function extract()
7071
$count = 1;
7172

7273
$testProductXpath = $this->theme->getCartSummaryCheckoutProductLoopNameXpath($count);
74+
$this->webDriver->wait()->until(ExpectedCondition::elementExists($testProductXpath, WebDriver::BY_XPATH));
7375

7476
while ($this->webDriver->elementExists($testProductXpath, WebDriver::BY_XPATH)) {
7577

0 commit comments

Comments
 (0)