Exemplo n.º 1
0
 def check(*argv, **kwargs):
     try:
         result = fun(*argv, **kwargs)
     except:
         raise
     else:
         process_unhandled_exceptions()
     return result
Exemplo n.º 2
0
 def check(*argv, **kwargs):
     try:
         result = fun(*argv, **kwargs)
     except:
         raise
     else:
         process_unhandled_exceptions()
     return result
Exemplo n.º 3
0
    def tearDown(self):
        self.tearDownCleanup()
        self.annotate(self._testMethodName, start=False)

        process_unhandled_exceptions()
        process_unhandled_twisted_exceptions()

        self.watchdog.join(2)
        if self.watchdog.is_alive():
            self._logger.critical("The WatchDog didn't stop!")
            self.watchdog.print_all_stacks()
            raise RuntimeError("Couldn't stop the WatchDog")

        if self.file_server:
            yield maybeDeferred(self.file_server.stopListening).addCallback(self.checkReactor)
        else:
            yield self.checkReactor("tearDown")
Exemplo n.º 4
0
    def tearDown(self):
        self.annotate(self._testMethodName, start=False)

        process_unhandled_exceptions()
        process_unhandled_twisted_exceptions()

        self.watchdog.join(2)
        if self.watchdog.is_alive():
            self._logger.critical("The WatchDog didn't stop!")
            self.watchdog.print_all_stacks()
            raise RuntimeError("Couldn't stop the WatchDog")

        if self.file_server:
            yield maybeDeferred(self.file_server.stopListening).addCallback(self.checkReactor)
        else:
            yield self.checkReactor("tearDown")

        super(AbstractServer, self).tearDown()