Exemplo n.º 1
0
        public void 키의_이름과_문의_이름이_일치하지_않으면_열리지않는가()
        {
            Door   door   = new Door("ClassRoom", 0, 0, 5, 3);
            Key    key    = new Key("LabroomKey", 0, 0, 0, 3);
            Player player = new Player(0, 0, 0, 3, false);

            player.GripItem(key);
            player.Move(0, 0, 3);
            player.OpenDoor(door);

            Assert.AreEqual(false, door.isOpened);
        }
Exemplo n.º 2
0
        public void 키의_이름과_문의_이름이_일치하면_열리는가()
        {
            Door   door   = new Door("Labroom", 0, 0, 5, 3);
            Item   key    = new Key("LabroomKey", 0, 0, 2, 3);
            Player player = new Player(0, 0, 0, 3, false);

            player.GripItem(key);
            player.Move(0, 0, 3);
            player.OpenDoor(door);

            Assert.AreEqual(true, door.isOpened);
        }