Exemplo n.º 1
0
 private void CSiApplication_Application_Start_with_Invalid_Model_Path()
 {
     using (CSiApplication app = new CSiApplication(CSiData.pathApp))
     {
         app.ApplicationStart(filePath: "FooBar.BadType");
     }
 }
Exemplo n.º 2
0
        public void CSiApplication_Application_Start_Default()
        {
            bool programWasOpened;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart();
                programWasOpened = true;
            }
            Assert.IsTrue(programWasOpened);
        }
Exemplo n.º 3
0
        public void CSiApplication_Application_Start_with_Valid_Model_Path()
        {
            bool programWasOpened;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(filePath: Path.Combine(CSiData.pathResources, CSiData.pathModelDemo + CSiData.extension));
                programWasOpened = true;
            }
            Assert.IsTrue(programWasOpened);
        }
Exemplo n.º 4
0
        public void CSiApplication_Application_Start_with_Invisible_is_Invisible()
        {
            bool programIsVisible = true;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(visible: false);
                programIsVisible = app.Visible();
            }
            Assert.IsFalse(programIsVisible);
        }
Exemplo n.º 5
0
        public void CSiApplication_Application_Start_with_Custom_Units()
        {
            bool programWasOpened;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(eUnits.kgf_mm_C);
                programWasOpened = true;
            }
            Assert.IsTrue(programWasOpened);
        }
Exemplo n.º 6
0
        public void CSiApplication_Application_Start_Default_is_Visible()
        {
            bool programIsVisible;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(visible: true);
                programIsVisible = app.Visible();
            }
            Assert.IsTrue(programIsVisible);
        }
Exemplo n.º 7
0
        public void CSiApplication_Show_Visible_Shows()
        {
            bool programIsVisible;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(visible: true);
                programIsVisible = app.Visible();
                Assert.IsTrue(programIsVisible);

                app.Unhide();
                programIsVisible = app.Visible();
                Assert.IsTrue(programIsVisible);
            }
        }
Exemplo n.º 8
0
        public void CSiApplication_Hide_Hidden_Hides()
        {
            bool programIsVisible = true;

            using (CSiApplication app = new CSiApplication(CSiData.pathApp))
            {
                app.ApplicationStart(visible: false);
                programIsVisible = app.Visible();
                //Assert.IsFalse(programIsVisible); // TODO: This is suppressed as there is a problem with initializing hidden.

                app.Hide();
                programIsVisible = app.Visible();
                Assert.IsFalse(programIsVisible);

                app.Hide();
                programIsVisible = app.Visible();
                Assert.IsFalse(programIsVisible);
            }
        }
Exemplo n.º 9
0
 public void Setup()
 {
     _app = new CSiApplication(CSiData.pathApp);
     _app.ApplicationStart(filePath: CSiData.pathResources + @"\" + CSiData.pathModelSet + CSiData.extension);
 }