コード例 #1
0
        public void should_park_in_any_parkingLot_for_multiple_empty_parkingLots_with_different_size()
        {
            var car = new Car();
            var superboy = new SuperParkingBoy(new ParkingLot(10), new ParkingLot(20));

            var parkingInfo = superboy.Park(car);

            Assert.Same(car, superboy.Pick(parkingInfo));
        }
コード例 #2
0
        public void superBoy_should_pick_success_after_superBoy_park()
        {
            var car=new Car();
            var parkinglot = new ParkingLot();
            var superBoy = new SuperParkingBoy(parkinglot);

            var parkingInfo = superBoy.Park(car);

            Assert.Same(car,superBoy.Pick(parkingInfo));
        }
コード例 #3
0
        public void should_pick_by_selectedBoy_when_selected_boy_park()
        {
            var car = new Car();
            var superParkingBoy = new SuperParkingBoy(new ParkingLot());
            var manager = new ParkingBoyManager(
                new List<IParkable> { superParkingBoy});

            Assert.Same(car, superParkingBoy.Pick(manager.Park(car)));
        }