Exemple #1
0
        public void DeleteMediaTest()
        {
            SatelliteGroundStationControler satelliteGroundStationControler;

            // 测试用例1
            satelliteGroundStationControler = new SatelliteGroundStationControler();
            satelliteGroundStationControler.DeleteMedia
                ((Dictionary <string, object>)null);
            Assert.IsNotNull((object)satelliteGroundStationControler);
            Assert.AreEqual <string>
                ("127.0.0.1", ((BaseService)satelliteGroundStationControler).Server);
            Assert.AreEqual <int>(8080, ((BaseService)satelliteGroundStationControler).Port);

            // 测试用例2
            Dictionary <string, object> dictionary;

            satelliteGroundStationControler = new SatelliteGroundStationControler();
            dictionary     = new Dictionary <string, object>(0);
            dictionary[""] = (object)null;
            satelliteGroundStationControler.DeleteMedia(dictionary);
            Assert.IsNotNull((object)satelliteGroundStationControler);
            Assert.AreEqual <string>
                ("127.0.0.1", ((BaseService)satelliteGroundStationControler).Server);
            Assert.AreEqual <int>(8080, ((BaseService)satelliteGroundStationControler).Port);
        }
        public FormSatelliteGroundStationManage()
        {
            InitializeComponent();

            this.m_SatelliteGroundStationControler              = new SatelliteGroundStationControler();
            this.m_SatelliteGroundStationControler.QueryEvent  += m_ServiceController_QueryEvent;
            this.m_SatelliteGroundStationControler.DeleteEvent += m_ServiceController_DeleteEvent;
        }
Exemple #3
0
        public void DeleteMediaTest1()
        {
            SatelliteGroundStationControler satelliteGroundStationControler;

            satelliteGroundStationControler = new SatelliteGroundStationControler();
            satelliteGroundStationControler.DeleteMedia((string)null);
            Assert.IsNotNull((object)satelliteGroundStationControler);
            Assert.AreEqual <string>
                ("127.0.0.1", ((BaseService)satelliteGroundStationControler).Server);
            Assert.AreEqual <int>(8080, ((BaseService)satelliteGroundStationControler).Port);
        }
        public FormSatelliteGroundStation(OperationType type, Fire_SatelliteGroundStation satelliteGroundStation = null)
        {
            InitializeComponent();

            this.m_OperationType                   = type;
            this.m_SatelliteGroundStation          = satelliteGroundStation;
            this.m_SatelliteGroundStationControler = new SatelliteGroundStationControler();

            this.m_SatelliteGroundStationControler.AddEvent         += M_ServiceController_AddEvent;
            this.m_SatelliteGroundStationControler.EditEvent        += M_ServiceController_EditEvent;
            this.m_SatelliteGroundStationControler.AddMediaEvent    += M_SatelliteGroundStationControler_AddMediaEvent;
            this.m_SatelliteGroundStationControler.DeleteMediaEvent += M_SatelliteGroundStationControler_DeleteMediaEvent;

            this.mediaControl1.AddEvent    += MediaControl1_AddEvent;
            this.mediaControl1.DeleteEvent += MediaControl1_DeleteEvent;
        }
Exemple #5
0
        public void EditTest()
        {
            SatelliteGroundStationControler satelliteGroundStationControler;

            // 测试用例1
            satelliteGroundStationControler = new SatelliteGroundStationControler();
            satelliteGroundStationControler.Edit((Fire_SatelliteGroundStation)null);
            Assert.IsNotNull((object)satelliteGroundStationControler);
            Assert.AreEqual <string>
                ("127.0.0.1", ((BaseService)satelliteGroundStationControler).Server);
            Assert.AreEqual <int>(8080, ((BaseService)satelliteGroundStationControler).Port);

            // 测试用例2
            satelliteGroundStationControler = new SatelliteGroundStationControler();
            Fire_SatelliteGroundStation s0 = new Fire_SatelliteGroundStation();

            s0.objectid      = 0;
            s0.name          = (string)null;
            s0.address       = (string)null;
            s0.manager       = (string)null;
            s0.phone         = (string)null;
            s0.longitude     = 0;
            s0.latitude      = 0;
            s0.waveband      = (string)null;
            s0.antdiameter   = 0;
            s0.ip            = (string)null;
            s0.cre_time      = (string)null;
            s0.cre_pers      = (string)null;
            s0.mod_time      = (string)null;
            s0.mod_pers      = (string)null;
            s0.shape         = (string)null;
            s0.status        = (string)null;
            s0.picture1      = (string)null;
            s0.picture2      = (string)null;
            s0.video         = (string)null;
            s0.note          = (string)null;
            s0.id            = (string)null;
            s0.pac           = (string)null;
            s0.mediaByteDict = (Dictionary <string, object>)null;
            s0.mediaFiles    = (List <MediaFile>)null;
            satelliteGroundStationControler.Edit(s0);
            Assert.IsNotNull((object)satelliteGroundStationControler);
            Assert.AreEqual <string>
                ("127.0.0.1", ((BaseService)satelliteGroundStationControler).Server);
            Assert.AreEqual <int>(8080, ((BaseService)satelliteGroundStationControler).Port);
        }