Inheritance: IUserInterface
Esempio n. 1
0
        public static TestUI Create()
        {
            TestUI     ui         = new TestUI();
            Controller controller = new Controller(ui);

            return(ui);
        }
Esempio n. 2
0
        public void ExportRouteGadget2()
        {
            string ppenFileName  = TestUtil.GetTestFile(@"routegadget\GRC.ppen");
            string xmlFileName   = TestUtil.GetTestFile(@"routegadget\GRC.xml");
            string gifFileName   = TestUtil.GetTestFile(@"routegadget\GRC.gif");
            string worldFileName = TestUtil.GetTestFile(@"routegadget\GRC.gfw");

            TestUI     ui         = TestUI.Create();
            Controller controller = ui.controller;

            bool success = controller.LoadInitialFile(ppenFileName, true);

            Assert.IsTrue(success);

            controller.MapDisplay.SetCourse(controller.GetCourseLayout());

            success = controller.ExportRouteGadget(xmlFileName, gifFileName, 3);
            Assert.IsTrue(success);

            Dictionary <string, string> exceptions = ExportXmlVersion3.TestFileExceptionMap();

            TestUtil.CompareBitmapBaseline((Bitmap)Image.FromFile(gifFileName), TestUtil.GetTestFile(@"routegadget\GRC GIF.baseline.png"));
            TestUtil.CompareTextFileBaseline(xmlFileName, TestUtil.GetTestFile(@"routegadget\GRC XML.baseline.xml"), exceptions);
            TestUtil.CompareTextFileBaseline(worldFileName, TestUtil.GetTestFile(@"routegadget\GRC World File.baseline.gfw"), exceptions);

            File.Delete(xmlFileName);
            File.Delete(gifFileName);
            File.Delete(worldFileName);
        }
Esempio n. 3
0
        public void Setup(string filename)
        {
            ui         = TestUI.Create();
            controller = ui.controller;
            bool success = controller.LoadInitialFile(TestUtil.GetTestFile(filename), true);

            Assert.IsTrue(success);
        }
Esempio n. 4
0
        public void Setup()
        {
            ui         = TestUI.Create();
            controller = ui.controller;
            eventDB    = controller.GetEventDB();

            string fileName = TestUtil.GetTestFile("modes\\crossings.ppen");

            bool success = controller.LoadInitialFile(fileName, true);

            Assert.IsTrue(success);
        }
Esempio n. 5
0
        public void Setup(string filename)
        {
            ui = TestUI.Create();
            controller = ui.controller;
            eventDB = controller.GetEventDB();

            string fileName = TestUtil.GetTestFile(filename);

            bool success = controller.LoadInitialFile(fileName, true);
            Assert.IsTrue(success);
        }
Esempio n. 6
0
 public void Setup()
 {
     ui         = TestUI.Create();
     controller = ui.controller;
 }
 public void Setup()
 {
     ui = TestUI.Create();
     controller = ui.controller;
 }
Esempio n. 8
0
 public static TestUI Create()
 {
     TestUI ui = new TestUI();
     Controller controller = new Controller(ui);
     return ui;
 }
        public void Setup()
        {
            ui = TestUI.Create();
            controller = ui.controller;
            eventDB = controller.GetEventDB();

            string fileName = TestUtil.GetTestFile("modes\\marymoor.coursescribe");

            bool success = controller.LoadInitialFile(fileName, true);
            Assert.IsTrue(success);
        }
 public void Setup()
 {
     ui = TestUI.Create();
     controller = ui.controller;
     selectionMgr = controller.GetSelectionMgr();
     eventDB = controller.GetEventDB();
 }
Esempio n. 11
0
 public void Setup()
 {
     ui           = TestUI.Create();
     controller   = ui.controller;
     selectionMgr = controller.GetSelectionMgr();
 }