public static void Main()
        {
            var productComparer = new ProductComparer();

            productComparer.Add(new Product(TariffConstants.BasicTariffName));
            productComparer.Add(new Product(TariffConstants.PackagedTariffName));

            productComparer.CompareAndPrint(3500);
            productComparer.CompareAndPrint(4500);
            productComparer.CompareAndPrint(6000);
        }
Esempio n. 2
0
        public void CompareAndPrintShouldSuccess()
        {
            // Arrange
            var productComparer = new ProductComparer();
            var product1        = new Product(TariffConstants.BasicTariffName);
            var product2        = new Product(TariffConstants.PackagedTariffName);

            // Act
            productComparer.Add(product1);
            productComparer.Add(product2);
            productComparer.CompareAndPrint(3400);
        }