コード例 #1
0
        public void PaymentFactory_Should_Generate_FreeVideoSlip()
        {
            int      video         = PaymentType.Video.GetHashCode();
            IPayment paymentObject = PaymentFactory.GetPaymentObject(video);
            bool     result        = paymentObject.ProcessPayment();

            Assert.AreEqual(result, true);
        }
コード例 #2
0
        public void PaymentFactory_Should_UpgradeMembership()
        {
            int      upgrade       = PaymentType.MembershipUpgrade.GetHashCode();
            IPayment paymentObject = PaymentFactory.GetPaymentObject(upgrade);
            bool     result        = paymentObject.ProcessPayment();

            Assert.AreEqual(result, true);
        }
コード例 #3
0
        public void PaymentFactory_Should_ActiavteMembership()
        {
            int      activate      = PaymentType.EmployeeMemeberActivate.GetHashCode();
            IPayment paymentObject = PaymentFactory.GetPaymentObject(activate);
            bool     result        = paymentObject.ProcessPayment();

            Assert.AreEqual(result, true);
        }
コード例 #4
0
        public void PaymentFactory_Create_DuplicatePackagingSlip_RoyaltyDep_ForBook()
        {
            int      book          = PaymentType.Employee.GetHashCode();
            IPayment paymentObject = PaymentFactory.GetPaymentObject(book);
            bool     result        = paymentObject.ProcessPayment();

            Assert.AreEqual(result, true);
        }
コード例 #5
0
        public void PaymentFactory_Should_Generate_PackagingSlip_ForPhysicalProduct()
        {
            int      physicalProduct = PaymentType.ProductDetails.GetHashCode();
            IPayment paymentObject   = PaymentFactory.GetPaymentObject(physicalProduct);

            bool result = paymentObject.ProcessPayment();

            Assert.AreEqual(result, true);
        }
コード例 #6
0
        public void PaymentFactory_Should_UpgradeMembership()
        {
            //Arrange
            int          upgrade       = PaymentTypeInformation.MembershipUpgrade.GetHashCode();
            IPaymentinfo paymentObject = PaymentFactory.GetPaymentObject(upgrade);
            //Act
            bool result = paymentObject.ProcessPaymentInformation();

            //Assert
            Assert.AreEqual(result, true);
        }
コード例 #7
0
        public void PaymentFactory_Create_DuplicatePackagingSlip_RoyaltyDep_ForBook()
        {
            //Arrange
            int          book          = PaymentTypeInformation.Book.GetHashCode();
            IPaymentinfo paymentObject = PaymentFactory.GetPaymentObject(book);
            //Act
            bool result = paymentObject.ProcessPaymentInformation();

            //Assert
            Assert.AreEqual(result, true);
        }
コード例 #8
0
        public void PaymentFactory_Should_Generate_PackagingSlip_ForPhysicalProduct()
        {
            //Arrange
            int          physicalProduct = PaymentTypeInformation.PhysicalProduct.GetHashCode();
            IPaymentinfo paymentObject   = PaymentFactory.GetPaymentObject(physicalProduct);
            //Act
            bool result = paymentObject.ProcessPaymentInformation();

            //Assert
            Assert.AreEqual(result, true);
        }
コード例 #9
0
        public void PaymentFactory_Should_ActiavteMembership()
        {
            //Arrange
            int      activate      = PaymentType.MembershipActivate.GetHashCode();
            IPayment paymentObject = PaymentFactory.GetPaymentObject(activate);
            //Act
            bool result = paymentObject.ProcessPayment();

            //Assert
            Assert.AreEqual(result, true);
        }
コード例 #10
0
        public void PaymentFactory_Should_Generate_FreeVideoSlip()
        {
            //Arrange
            int          video         = PaymentTypeInformation.Video.GetHashCode();
            IPaymentinfo paymentObject = PaymentFactory.GetPaymentObject(video);

            PaymentFactory.GetPaymentObject(video);
            //Act
            bool result = paymentObject.ProcessPaymentInformation();

            //Assert
            Assert.AreEqual(result, true);
        }