示例#1
0
    def create_test_workspace(self):
        """
        Create a test workspace.

        This function copies the test sources into the working directory.
        """
        fileutils.sync_tree(self.test_dir, self.working_dir())
    def create_test_workspace(self):
        """
        Create a test workspace.

        This function copies the test sources into the working directory.
        """

        fileutils.sync_tree(self.test_dir, self.working_dir())
示例#3
0
    def tear_up(self):
        super(PythonDriver, self).tear_up()
        fileutils.sync_tree(self.test_env['test_dir'], self.test_working_dir())

        # See if we expect a failure for this testcase
        try:
            comment = self.test_env['expect_failure']
        except KeyError:
            self.expect_failure = False
            self.expect_failure_comment = ''
        else:
            self.expect_failure = True
            if not (comment is None or isinstance(comment, basestring)):
                self.result.set_status(
                    'PROBLEM',
                    'Invalid "expect_failure" entry: expected a string but got'
                    ' {}'.format(repr(comment)))
                return
            # Because of wrapping in the YAML file, we can get multi-line
            # strings, which is not valid for comments.
            self.expect_failure_comment = comment.replace('\n', ' ').strip()
示例#4
0
文件: support.py 项目: AdaCore/gsh
 def tear_up(self):
     self.test_tmp = os.path.join(self.global_env['working_dir'],
                                  self.test_env['test_name'])
     sync_tree(self.test_env['test_dir'], self.test_tmp)
     self.register_path_subst(self.test_tmp, '<TEST_DIR>')
示例#5
0
 def deploy(self, dest):
     sync_tree(self.path, dest, delete=True)
示例#6
0
 def deploy(self, dest):
     sync_tree(self.path, dest, delete=True)
示例#7
0
 def tear_up(self):
     self.test_tmp = os.path.join(self.global_env['working_dir'],
                                  self.test_env['test_name'])
     sync_tree(self.test_env['test_dir'], self.test_tmp)
     self.register_path_subst(self.test_tmp, '<TEST_DIR>')