예제 #1
0
파일: Form1.cs 프로젝트: fxj1988/WCFGit
        // 登陆测试,登陆成功后,修改数据库remarks=“登陆成功”并返回用户信息
        private static appleAcount LoginTest(ServiceContractClient client)
        {
            appleAcount user = client.Login();

            userInfo = user;
            OrderMethods orderMethod = new OrderMethods();
            string       loginResult = orderMethod.LoginTest(user.loginAppleId, user.loginPassword);

            user.remarks = loginResult;
            client.EditUserInfo(user);
            return(user);
        }
예제 #2
0
        static void Main(string[] args)
        {
            int       t  = 1;
            Stopwatch sw = new Stopwatch();

            sw.Start();
            appleAcount user;

            while (client.GetOrder() == "写入测试")
            {
                user = client.ParallelTest();
                Console.WriteLine("ID:" + user.ID + "\t");
                user.cookies = DBNull.Value.ToString();
                int x = client.EditUserInfo(user);
                Console.Write("写入次数:" + t + "\t" + "写入时间间隔:" + sw.ElapsedMilliseconds + "\tID:" + x + "\r\n");
                t++;
                sw.Restart();
            }
            Console.Read();
        }