Author: Arkadiusz Krakowiak (arkadiusz.krakowiak@lakion.com)
Inheritance: extends Sylius\Behat\Page\Admin\Crud\UpdatePageInterface
 /**
  * @Then /^there should still be only one taxon with code "([^"]+)"$/
  */
 public function thereShouldStillBeOnlyOneTaxonWithCode($code)
 {
     Assert::true($this->updatePage->hasResourceValues(['code' => $code]), sprintf('Taxon with code %s cannot be found.', $code));
 }
Esempio n. 2
0
 /**
  * @Then I should be notified that the :imageNumber image should have an unique code
  */
 public function iShouldBeNotifiedThatTheFirstImageShouldHaveAnUniqueCode($imageNumber)
 {
     preg_match_all('!\\d+!', $imageNumber, $matches);
     Assert::same($this->updatePage->getValidationMessageForImageAtPlace((int) $matches[0][0] - 1), 'Image code must be unique within this taxon.');
 }
 /**
  * @Then the image code field should be disabled
  */
 public function theImageCodeFieldShouldBeDisabled()
 {
     Assert::true($this->updatePage->isImageCodeDisabled(), 'Image code field should be disabled but it is not.');
 }
 /**
  * @When I change the image with the :code code to :path
  */
 public function iChangeItsImageToPathForTheCode($path, $code)
 {
     $this->updatePage->changeImageWithCode($code, $path);
 }