Skip to content

Commit

Permalink
pr-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
SirDomin committed Jun 23, 2021
1 parent 3cb78c1 commit df21ee5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions src/Sylius/Behat/Context/Api/Shop/CheckoutContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -422,11 +422,13 @@ public function iTryToSelectPaymentMethod(string $paymentMethodCode): void
/**
* @Then I should be notified that the order should be addressed first
*/
public function iShouldBeNotifiedThatTheOrderShouldBeAddressedFirst()
public function iShouldBeNotifiedThatTheOrderShouldBeAddressedFirst(): void
{
Assert::same($this->ordersClient->getLastResponse()->getStatusCode(), Response::HTTP_UNPROCESSABLE_ENTITY);
$response = $this->ordersClient->getLastResponse();

Assert::same($response->getStatusCode(), Response::HTTP_UNPROCESSABLE_ENTITY);

$content = json_decode($this->ordersClient->getLastResponse()->getContent(), true);
$content = json_decode($response->getContent(), true);

Assert::same($content['message'], 'Order should be addressed first.');
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

namespace Sylius\Bundle\ApiBundle\Exception;

class OrderCannotBeShippedWithoutAddressing extends \RuntimeException
final class OrderCannotBeShippedWithoutAddressing extends \RuntimeException
{
public function __construct()
{
Expand Down

0 comments on commit df21ee5

Please sign in to comment.