<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SendWork.aspx.cs" Inherits="CCFlow.SDKFlowDemo.TestUnit.Test111" %>
<% String userNo = "admin"; BP.Port.Emp emp = new BP.Port.Emp(userNo); BP.Web.WebUser.SignInOfGener(emp); BP.WF.UnitTesting.TestAPI api = new BP.WF.UnitTesting.TestAPI(); api.No = "SendWork"; api.Name = "标准的工作发送"; api.Save(); BP.WF.UnitTesting.TestVer apiVer = new BP.WF.UnitTesting.TestVer(); apiVer.No = "SendWork002"; apiVer.Name = "版本" + apiVer.No; try { //定义了5个样本. 对该过程执行5次。 for (int idx = 0; idx < 5; idx++) { DateTime startTime = System.DateTime.Now; for (int i = 0; i <= 1000; i++) { long workid = BP.WF.Dev2Interface.Node_CreateBlankWork("065"); BP.WF.SendReturnObjs objs = BP.WF.Dev2Interface.Node_SendWork("065", workid, 0, "admin"); } //doSomeThing(); //要运行的java程序 DateTime endTime = System.DateTime.Now; TimeSpan ts = endTime - startTime; BP.WF.UnitTesting.TestSample dtl = new BP.WF.UnitTesting.TestSample(); dtl.MyPK = BP.DA.DBAccess.GenerGUID(); dtl.FK_API = api.No; dtl.FK_Ver = apiVer.No; dtl.DTFrom = startTime.ToShortTimeString(); dtl.DTTo = endTime.ToShortTimeString(); dtl.Name = api.Name + "-" + apiVer.Name; dtl.TimeUse = ts.TotalMilliseconds; //运行时间间隔长度(毫秒)/1000 (换算成秒)/1000(每次需要多少秒) // dtl.TimesPerSecond = 1/(ts.TotalMilliseconds / 1000/1000); dtl.Insert(); } apiVer.Insert(); //执行成功后,版本号在插入里面. } catch (Exception ex) { BP.WF.UnitTesting.TestSample dtl = new BP.WF.UnitTesting.TestSample(); dtl.Delete(BP.WF.UnitTesting.TestSampleAttr.FK_Ver, apiVer.No); throw ex; } this.Response.Redirect("/WF/Comm/Group.htm?EnsName=BP.WF.UnitTesting.TestSamples", true); %>
关于发送的标准测试
历史测试报告-徐淑浩-sqlserver 2018-9-16
历史测试报告-徐淑浩-oracle 2018-9-16
历史测试报告-徐淑浩-oracle 2018-9-16