/** * @When /^I want to modify the ("[^"]+" product variant)$/ * @When /^I want to modify (this product variant)$/ */ public function iWantToModifyAProduct(ProductVariantInterface $productVariant) { $this->updatePage->open(['id' => $productVariant->getId(), 'productId' => $productVariant->getProduct()->getId()]); }
/** * @Then /^(variant with code "[^"]+") for ("[^"]+" currency) and ("[^"]+" channel) should be priced at "(?:€|£|\$)([^"]+)"$/ */ public function theProductForCurrencyAndChannelShouldBePricedAt(ProductVariantInterface $productVariant, CurrencyInterface $currency, ChannelInterface $channel, $price) { $this->updatePage->open(['id' => $productVariant->getId(), 'productId' => $productVariant->getProduct()->getId()]); Assert::same($this->updatePage->getPricingConfigurationForChannelAndCurrencyCalculator($channel, $currency), $price); }