示例#1
0
        public void DieselShouldTellPrice()
        {
            var sut    = new PetrolEngine(new Diesel());
            var result = sut.ToString();

            Assert.AreEqual(result, "Diesel(1.1) Engine");
        }
示例#2
0
        public void MockShouldPrintOutFuelType()
        {
            var sut    = new PetrolEngine(_fuel);
            var result = sut.ToString();

            Assert.AreEqual(result, "Premium Petrol Engine");
        }