Автор: Arkadiusz Krakowiak (arkadiusz.krakowiak@lakion.com)
Наследование: extends Sylius\Behat\Page\SymfonyPageInterface
Пример #1
0
 /**
  * @param string $expectedNotification
  */
 private function assertNotification($expectedNotification)
 {
     $notifications = $this->orderDetails->getNotifications();
     $hasNotifications = '';
     foreach ($notifications as $notification) {
         $hasNotifications .= $notification;
         if ($notification === $expectedNotification) {
             return;
         }
     }
     throw new \RuntimeException(sprintf('There is no notificaiton with "%s". Got "%s"', $expectedNotification, $hasNotifications));
 }
Пример #2
0
 /**
  * @Then I should not be able to pay
  */
 public function iShouldNotBeAbleToPayAgain()
 {
     Assert::false($this->orderDetails->hasPayAction(), 'I should not be able to pay, but I am able to.');
 }
Пример #3
0
 /**
  * @Given /^I tried to pay(?:| again)$/
  * @When /^I try to pay(?:| again)$/
  */
 public function iTryToPayAgain()
 {
     $this->paypalApiMocker->performActionInApiInitializeScope(function () {
         $this->orderDetails->pay();
     });
 }