示例#1
0
        public void TestHealthStationWeighingCounter()
        {
            Person        mannen  = new Person("Superman", 35, 200, 300);
            HealthStation station = new HealthStation();

            station.Weigh(mannen);
            station.Weigh(mannen);
            station.Weigh(mannen);
            station.Weigh(mannen);

            Assert.AreEqual(4, station.weighings, "Station.Weigh(Person) should increase the weight and the 'int weighings' by one!");
        }
示例#2
0
        public void TestHealthStationWeighingAnother()
        {
            Person        mannen  = new Person("Master Blaster", 500, 3000, 300);
            HealthStation station = new HealthStation();

            Assert.AreEqual(3000, station.Weigh(mannen), "Station.Weigh(Person) should return the weight of the person!");
        }
示例#3
0
        public void TestHealthStationWeighing()
        {
            Person        mannen  = new Person("Superman", 35, 200, 300);
            HealthStation station = new HealthStation();

            Assert.AreEqual(200, station.Weigh(mannen), "Station.Weigh(Person) should return the weight of the person!");
        }
示例#4
0
        public void TestHealthStationFeeding()
        {
            Person        mannen  = new Person("Superman", 35, 200, 300);
            HealthStation station = new HealthStation();

            station.Feed(mannen);

            Assert.AreEqual(201, station.Weigh(mannen), "Station.Feed(Person) should increase the weight of the person by one!");
        }