PHP Class Sylius\Behat\Context\Ui\Shop\ProductContext

Author: Kamil Kokot ([email protected])
Author: Magdalena Banasiak ([email protected])
Author: Anna Walasek ([email protected])
Inheritance: implements Behat\Behat\Context\Context
Show file Open project: sylius/sylius

Public Methods

Method Description
__construct ( Sylius\Behat\Page\Shop\Product\ShowPageInterface $showPage, Sylius\Behat\Page\Shop\Product\IndexPageInterface $indexPage, Sylius\Behat\Page\Shop\ProductReview\IndexPageInterface $productReviewsIndexPage )
iCheckListOfProductsForTaxon ( Sylius\Component\Core\Model\TaxonInterface $taxon )
iCheckThisProductSReviews ( Sylius\Component\Core\Model\ProductInterface $product )
iClearFilter ( )
iOpenPage ( $url )
iOpenProductPage ( Sylius\Component\Core\Model\ProductInterface $product )
iSearchForProductsWithName ( $name )
iSelectVariant ( $variantName )
iSetItsOptionTo ( $optionName, $optionValue )
iShouldBeAbleToAccessProduct ( Sylius\Component\Core\Model\ProductInterface $product )
iShouldBeNotifiedThatThereAreNoReviews ( )
iShouldBeNotifiedThatThisProductDoesNotHaveSufficientStock ( Sylius\Component\Core\Model\ProductInterface $product )
iShouldBeOnProductDetailedPage ( Sylius\Component\Core\Model\ProductInterface $product )
iShouldBeUnableToAddItToTheCart ( )
iShouldNotBeAbleToAccessProduct ( Sylius\Component\Core\Model\ProductInterface $product )
iShouldNotBeNotifiedThatThisProductDoesNotHaveSufficientStock ( Sylius\Component\Core\Model\ProductInterface $product )
iShouldNotSeeProduct ( $productName )
iShouldNotSeeReviewTitled ( $title )
iShouldNotSeeReviewTitledInTheList ( $title )
iShouldSeeAMainImage ( )
iShouldSeeAsItsAverageRating ( $rating )
iShouldSeeAttributes ( $count )
iShouldSeeEmptyListOfProducts ( )
iShouldSeeItIsOutOfStock ( )
iShouldSeeNumberOfProductReviewsInTheList ( $count )
iShouldSeeProduct ( $productName )
iShouldSeeProductName ( $name )
iShouldSeeProductReviews ( $count )
iShouldSeeProductWithName ( $name )
iShouldSeeProductsInTheList ( $numberOfProducts )
iShouldSeeReviewsTitled ( $reviews )
iShouldSeeTheProductAssociationWithProducts ( $productAssociationName, array $products )
iShouldSeeTheProductAttributeWithValue ( $attributeName, $expectedAttribute )
iShouldSeeTheProductPrice ( $price )
iShouldSeeTheProductWithPrice ( $productName, $productPrice )
iViewSortedProductsFromTaxon ( $sortDirection, Sylius\Component\Core\Model\TaxonInterface $taxon )
theFirstAttributeShouldBe ( $name )
theFirstProductOnTheListShouldHaveName ( $name )
theLastAttributeShouldBe ( $name )
theyShouldHaveOrderLikeAnd ( $productNames )
thisProductAverageRatingShouldBe ( Sylius\Component\Core\Model\ProductInterface $product, $averageRating )

Private Methods

Method Description
assertIsProductIsInAssociation ( string $productName, string $productAssociationName )
getProductAttributes ( ) : Behat\Mink\Element\NodeElement[]

Method Details

__construct() public method

public __construct ( Sylius\Behat\Page\Shop\Product\ShowPageInterface $showPage, Sylius\Behat\Page\Shop\Product\IndexPageInterface $indexPage, Sylius\Behat\Page\Shop\ProductReview\IndexPageInterface $productReviewsIndexPage )
$showPage Sylius\Behat\Page\Shop\Product\ShowPageInterface
$indexPage Sylius\Behat\Page\Shop\Product\IndexPageInterface
$productReviewsIndexPage Sylius\Behat\Page\Shop\ProductReview\IndexPageInterface

iCheckListOfProductsForTaxon() public method

public iCheckListOfProductsForTaxon ( Sylius\Component\Core\Model\TaxonInterface $taxon )
$taxon Sylius\Component\Core\Model\TaxonInterface

iCheckThisProductSReviews() public method

public iCheckThisProductSReviews ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iClearFilter() public method

public iClearFilter ( )

iOpenPage() public method

public iOpenPage ( $url )

iOpenProductPage() public method

public iOpenProductPage ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iSearchForProductsWithName() public method

public iSearchForProductsWithName ( $name )

iSelectVariant() public method

public iSelectVariant ( $variantName )

iSetItsOptionTo() public method

public iSetItsOptionTo ( $optionName, $optionValue )

iShouldBeAbleToAccessProduct() public method

public iShouldBeAbleToAccessProduct ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iShouldBeNotifiedThatThereAreNoReviews() public method

iShouldBeNotifiedThatThisProductDoesNotHaveSufficientStock() public method

public iShouldBeNotifiedThatThisProductDoesNotHaveSufficientStock ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iShouldBeOnProductDetailedPage() public method

public iShouldBeOnProductDetailedPage ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iShouldBeUnableToAddItToTheCart() public method

iShouldNotBeAbleToAccessProduct() public method

public iShouldNotBeAbleToAccessProduct ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iShouldNotBeNotifiedThatThisProductDoesNotHaveSufficientStock() public method

public iShouldNotBeNotifiedThatThisProductDoesNotHaveSufficientStock ( Sylius\Component\Core\Model\ProductInterface $product )
$product Sylius\Component\Core\Model\ProductInterface

iShouldNotSeeProduct() public method

public iShouldNotSeeProduct ( $productName )

iShouldNotSeeReviewTitled() public method

public iShouldNotSeeReviewTitled ( $title )

iShouldNotSeeReviewTitledInTheList() public method

iShouldSeeAMainImage() public method

iShouldSeeAsItsAverageRating() public method

public iShouldSeeAsItsAverageRating ( $rating )

iShouldSeeAttributes() public method

public iShouldSeeAttributes ( $count )

iShouldSeeEmptyListOfProducts() public method

iShouldSeeItIsOutOfStock() public method

iShouldSeeNumberOfProductReviewsInTheList() public method

iShouldSeeProduct() public method

public iShouldSeeProduct ( $productName )

iShouldSeeProductName() public method

public iShouldSeeProductName ( $name )

iShouldSeeProductReviews() public method

public iShouldSeeProductReviews ( $count )

iShouldSeeProductWithName() public method

public iShouldSeeProductWithName ( $name )

iShouldSeeProductsInTheList() public method

public iShouldSeeProductsInTheList ( $numberOfProducts )

iShouldSeeReviewsTitled() public method

public iShouldSeeReviewsTitled ( $reviews )

iShouldSeeTheProductAssociationWithProducts() public method

public iShouldSeeTheProductAssociationWithProducts ( $productAssociationName, array $products )
$products array

iShouldSeeTheProductAttributeWithValue() public method

public iShouldSeeTheProductAttributeWithValue ( $attributeName, $expectedAttribute )

iShouldSeeTheProductPrice() public method

public iShouldSeeTheProductPrice ( $price )

iShouldSeeTheProductWithPrice() public method

public iShouldSeeTheProductWithPrice ( $productName, $productPrice )

iViewSortedProductsFromTaxon() public method

public iViewSortedProductsFromTaxon ( $sortDirection, Sylius\Component\Core\Model\TaxonInterface $taxon )
$taxon Sylius\Component\Core\Model\TaxonInterface

theFirstAttributeShouldBe() public method

public theFirstAttributeShouldBe ( $name )

theFirstProductOnTheListShouldHaveName() public method

theLastAttributeShouldBe() public method

public theLastAttributeShouldBe ( $name )

theyShouldHaveOrderLikeAnd() public method

public theyShouldHaveOrderLikeAnd ( $productNames )

thisProductAverageRatingShouldBe() public method

public thisProductAverageRatingShouldBe ( Sylius\Component\Core\Model\ProductInterface $product, $averageRating )
$product Sylius\Component\Core\Model\ProductInterface