Esempio n. 1
0
        public void ProgStartParaTestTest()
        {
            ProgPara para = new ProgPara
            {
                ServerAddress     = "192.168.2.19",
                ServerPort        = 48624,
                UserName          = "******",
                PlaybackTimeStart = DateTime.Now.AddDays(-1),
                PlaybackTimeEnd   = DateTime.Now.AddDays(1),
                PlaybackTime      = DateTime.Now.AddHours(-1),
                Channel           = 9,
                VideoInfo         = TestDataSource.SKNVideoDatSource.GetSKData1(),
                DefaultSaveDir    = Environment.CurrentDirectory,
                XmlCgfFullPath    = Environment.CurrentDirectory
            };

            JsonSerializerSettings settings = new JsonSerializerSettings();

            settings.ReferenceLoopHandling = ReferenceLoopHandling.Ignore;
            string str = JsonConvert.SerializeObject(para, settings);

            str = CommonMethod.StringEncrypt.Base64Encode(str);
            //ProgPara para1= JsonConvert.DeserializeObject<ProgPara>(str);

            //str = "12345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345123451234512345";
            StartProcess(@"G:\Working\Currency\VideoPlayControl\SKVideoRemotePlayer\bin\Debug", @"G:\Working\Currency\VideoPlayControl\SKVideoRemotePlayer\bin\Debug\SKVideoRemotePlayer.exe", str);
            //z7("123");
            CommonMethod.Common.Delay_Millisecond(3000);
            Assert.AreEqual(str, "123");
        }
Esempio n. 2
0
        public PubMethodTests()
        {
            ProgPara para = new ProgPara
            {
                ServerAddress     = "192.168.2.19",
                ServerPort        = 48624,
                UserName          = "******",
                PlaybackTimeStart = DateTime.Now.AddDays(-1),
                PlaybackTimeEnd   = DateTime.Now.AddDays(1),
                PlaybackTime      = DateTime.Now.AddHours(-1),
                Channel           = 1,
                VideoInfo         = TestDataSource.SKNVideoDatSource.GetSKData1(),
                DefaultSaveDir    = Environment.CurrentDirectory,
                XmlCgfFullPath    = Environment.CurrentDirectory
            };

            ProgPara.CurrentProgPara = para;
            VideoEnvironment_SKN.SKNVideoSDK_Init(para.ServerAddress, para.ServerPort, para.UserName, para.XmlCgfFullPath, para.DefaultSaveDir);
        }