Beispiel #1
0
        public void TestGetSector2()
        {
            PlanetWars pw = new PlanetWars(
                "P 0 2 1 5 0#0\n" +
                "P 1 0 1 5 0#1\n" +
                "go\n");

            Assert.AreEqual(Sectors.SouthEast, pw.GetSector(pw.GetPlanet(0), pw.GetPlanet(1)));
        }
Beispiel #2
0
        public void TestGetSector()
        {
            PlanetWars pw = new PlanetWars(
                "P 10.946215 11.757139 0 15 4#0\n" +
                "P 18.033072 20.11299 1 5 5#1\n" +
                "go\n");

            Assert.AreEqual(Sectors.NordEast, pw.GetSector(pw.GetPlanet(0), pw.GetPlanet(1)));
            Assert.AreEqual(Sectors.SouthWest, pw.GetSector(pw.GetPlanet(1), pw.GetPlanet(0)));
        }