Exemplo n.º 1
0
 def tearDown(self):
     res = getResults()
     # If a test fails or there is an exception dump
     # for QemuTarget only
     if (type(self.target).__name__ == "QemuTarget" and
             (self.id() in res.getErrorList() or
             self.id() in  res.getFailList())):
         self.tc.host_dumper.create_dir(self._testMethodName)
         self.tc.host_dumper.dump_host()
         self.target.target_dumper.dump_target(
                 self.tc.host_dumper.dump_dir)
         print ("%s dump data stored in %s" % (self._testMethodName,
                  self.tc.host_dumper.dump_dir))
Exemplo n.º 2
0
    def tearDown(self):
        res = getResults()
        # If a test fails or there is an exception dump
        # for QemuTarget only
        if (type(self.target).__name__ == "QemuTarget"
                and (self.id() in res.getErrorList()
                     or self.id() in res.getFailList())):
            self.tc.host_dumper.create_dir(self._testMethodName)
            self.tc.host_dumper.dump_host()
            self.target.target_dumper.dump_target(self.tc.host_dumper.dump_dir)
            print("%s dump data stored in %s" %
                  (self._testMethodName, self.tc.host_dumper.dump_dir))

        self.tearDownLocal()