def test_event_lifetime(self):
     perf_metric = PerfMetric(name)
     perf_metric.event_start(event_name, event_begin)
     perf_metric.event_end(event_name, event_end)
     self.assertEqual(
         1000,
         perf_metric.event_lifetime(event_name, check_active_event=True))
 def test_event_lifetime(self):
     perf_metric = PerfMetric(name)
     perf_metric.event_start(event_name, event_begin)
     perf_metric.event_end(event_name, event_end)
     self.assertEqual(
         1000, perf_metric.event_lifetime(
             event_name, check_active_event=True))
 def test_event_end(self):
     perf_metric = PerfMetric(name)
     perf_metric.event_start(event_name, event_begin)
     perf_metric.event_end(event_name, event_end)
     self.assertEqual(event_end_repr, perf_metric.__repr__())
 def test_event_end(self):
     perf_metric = PerfMetric(name)
     perf_metric.event_start(event_name, event_begin)
     perf_metric.event_end(event_name, event_end)
     self.assertEqual(event_end_repr, perf_metric.__repr__())