コード例 #1
0
        public void AddBundleShouldAddBundleProductsToOrder()
        {
            // Given
            A.CallTo(() => _addBundleToOrderCommand.Run(Constants.IphoneCaseOrder.Id, Constants.IphoneBundle.Id))
            .DoesNothing();

            // When
            _ordersController.AddBundle(Constants.IphoneCaseOrder.Id, new BundleWrapper(Constants.IphoneBundle.Id));

            // Then
            A.CallTo(() => _addBundleToOrderCommand.Run(Constants.IphoneCaseOrder.Id, Constants.IphoneBundle.Id))
            .MustHaveHappened();
        }