Beispiel #1
0
        public void TestShipProcessingCommands()
        {
            World    testWorld = new World();
            Vector2D shipLoc   = new Vector2D(0, 0);

            Ship test1 = new Ship(1, shipLoc, shipLoc, false, "testName", 5, 0);

            test1.queueCommands("TL");
            Assert.AreEqual("TL", test1.GetCommands());
            test1.ProcessCommands();
            test1.queueCommands("RT");
            Assert.AreEqual("RT", test1.GetCommands());
            test1.ProcessCommands();
            test1.queueCommands("F");
            Assert.AreEqual("F", test1.GetCommands());
            test1.ProcessCommands();

            testWorld.updateShips();
        }