Lines Matching refs:event
21 from acts.event import event_bus
22 from acts.event.event import Event
23 from acts.event.event import TestCaseBeginEvent
24 from acts.event.event import TestCaseEndEvent
25 from acts.event.event import TestCaseEvent
26 from acts.event.event import TestClassBeginEvent
27 from acts.event.event import TestClassEndEvent
28 from acts.event.event import TestClassEvent
54 def get_context_for_event(event): argument
66 if isinstance(event, TestCaseEvent):
67 return _get_context_for_test_case_event(event)
68 if isinstance(event, TestClassEvent):
69 return _get_context_for_test_class_event(event)
70 raise TypeError('Unrecognized event type: %s %s', event, event.__class__)
73 def _get_context_for_test_case_event(event): argument
75 return TestCaseContext(event.test_class, event.test_case)
78 def _get_context_for_test_class_event(event): argument
80 return TestClassContext(event.test_class)
95 def _update_test_class_context(event): argument
103 if isinstance(event, TestClassBeginEvent):
104 _contexts.append(_get_context_for_test_class_event(event))
105 if isinstance(event, TestClassEndEvent):
111 def _update_test_case_context(event): argument
119 if isinstance(event, TestCaseBeginEvent):
120 _contexts.append(_get_context_for_test_case_event(event))
121 if isinstance(event, TestCaseEndEvent):