'Trapping a L{Failure}.'

def test_failAndTrap(self):

    try:
        raise NotImplementedError('test')
    except:
        f = failure.Failure()
    error = f.trap(SystemExit, RuntimeError)
    self.assertEqual(error, RuntimeError)
    self.assertEqual(f.type, NotImplementedError)
