Dumplie\Customer\Tests\Integration\Application\Generic\CartTestCase::test_adding_new_products_to_cart PHP Method

test_adding_new_products_to_cart() public method

    function test_adding_new_products_to_cart()
    {
        $cartId = $this->customerContext->createEmptyCart('EUR');
        $command = new AddToCart('SKU_1', 2, (string) $cartId);
        $this->customerContext->commandBus()->handle($command);
        $this->clear();
        $this->assertCount(1, $this->customerContext->carts()->getById($cartId)->items());
    }