'L{_ThreePhaseEvent.fireEvent} should call I{before}, I{during}, and
I{after} phase triggers in that order.'

def test_fireEvent(self):

    events = []
    self.event.addTrigger('after', events.append, ('first', 'after'))
    self.event.addTrigger('during', events.append, ('first', 'during'))
    self.event.addTrigger('before', events.append, ('first', 'before'))
    self.event.addTrigger('before', events.append, ('second', 'before'))
    self.event.addTrigger('during', events.append, ('second', 'during'))
    self.event.addTrigger('after', events.append, ('second', 'after'))
    self.assertEqual(events, [])
    self.event.fireEvent()
    self.assertEqual(events, [('first', 'before'), ('second', 'before'), ('first', 'during'), ('second', 'during'), ('first', 'after'), ('second', 'after')])
