示例#1
0
 private static void HandleCompletedEvent(object sender, TestCompletedEventArgs args)
 {
     StringBuilder builder = new StringBuilder();
     builder.AppendLine("Simulation completed: ");
     builder.AppendLine("Total number of user: "******"Test duration: " + args.ActualTestDuration.ToString());
     builder.AppendLine("Max number of concurrent users: " + args.MaxNumberConcurrentUsers.ToString());
     builder.AppendLine("Average number of concurrent users: " + args.AverageConcurrentUsers.ToString());
     builder.AppendLine("Average response time: " + args.AverageResponseTime + " milliseconds.");
     builder.AppendLine("Total hits: " + args.Hits.ToString());
     builder.AppendLine("Total errors: " + args.Errors.ToString());
     builder.AppendLine("Total timeouts: " + args.Timeouts.ToString());
     Console.WriteLine(builder.ToString());
 }
示例#2
0
 // Invoke the Changed event; called whenever list changes
 protected virtual void OnTestCompleted(TestCompletedEventArgs e)
 {
     if (TestCompleted != null)
         TestCompleted(this, e);
 }