PHP Class spec\Sylius\Bundle\ProductBundle\Validator\ProductVariantCombinationValidatorSpec

Inheritance: extends PhpSpec\ObjectBehavior
Mostra file Open project: sylius/sylius

Public Methods

Method Description
it_adds_violation_if_variant_with_given_same_options_already_exists ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
it_does_not_add_violation_if_product_does_not_have_options ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
it_does_not_add_violation_if_product_does_not_have_variants ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
it_is_a_constraint_validator ( )
it_is_initializable ( )
let ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )

Method Details

it_adds_violation_if_variant_with_given_same_options_already_exists() public method

public it_adds_violation_if_variant_with_given_same_options_already_exists ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
$context Symfony\Component\Validator\Context\ExecutionContextInterface
$product Sylius\Component\Product\Model\ProductInterface
$variant Sylius\Component\Product\Model\ProductVariantInterface
$variantsParityChecker Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface

it_does_not_add_violation_if_product_does_not_have_options() public method

public it_does_not_add_violation_if_product_does_not_have_options ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
$context Symfony\Component\Validator\Context\ExecutionContextInterface
$product Sylius\Component\Product\Model\ProductInterface
$variant Sylius\Component\Product\Model\ProductVariantInterface
$variantsParityChecker Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface

it_does_not_add_violation_if_product_does_not_have_variants() public method

public it_does_not_add_violation_if_product_does_not_have_variants ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Model\ProductInterface $product, Sylius\Component\Product\Model\ProductVariantInterface $variant, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
$context Symfony\Component\Validator\Context\ExecutionContextInterface
$product Sylius\Component\Product\Model\ProductInterface
$variant Sylius\Component\Product\Model\ProductVariantInterface
$variantsParityChecker Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface

it_is_a_constraint_validator() public method

it_is_initializable() public method

public it_is_initializable ( )

let() public method

public let ( Symfony\Component\Validator\Context\ExecutionContextInterface $context, Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface $variantsParityChecker )
$context Symfony\Component\Validator\Context\ExecutionContextInterface
$variantsParityChecker Sylius\Component\Product\Checker\ProductVariantsParityCheckerInterface