Esempio n. 1
0
        public void CalculatesMonthlyRenumeration()
        {
            // Arrange
            IEmployee        salariedEmployee = new SalariedEmployee();
            IEmployeeVisitor visitor          = new CalculateRenumeration();

            // Act
            var result = salariedEmployee.Accept(visitor);

            // Assert
            Assert.AreEqual("renumeration", result);
        }
Esempio n. 2
0
        public void CalculatesHourly()
        {
            // Arrange
            IEmployee        salariedEmployee = new SalariedEmployee();
            IEmployeeVisitor visitor          = new CalculateRate();

            // Act
            var result = salariedEmployee.Accept(visitor);

            // Assert
            Assert.AreEqual("rate", result);
        }