Ejemplo n.º 1
0
 def test_ssh_plugin(self):
     job_path = "ssh_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.load(f)
     commands = [[], []]
     init_plugins(jobconfig, commands, "../src/plugins", ".", "worker")
Ejemplo n.º 2
0
 def test_cmd_plugin_with_prerequisites(self):
     job_path = "cmd_with_prerequisites_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.safe_load(f)
     commands = [[], []]
     initializer.init_plugins(jobconfig, {}, {}, "", commands,
                              "../src/plugins", ".", "worker")
Ejemplo n.º 3
0
 def test_ssh_plugin(self):
     job_path = "ssh_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.safe_load(f)
     commands = [[], []]
     initializer.init_plugins(
         jobconfig, {"userssh": "ssh-rsa AAAAB3N/cTbWGQZtN1pai-ssh"}, {},
         "", commands, "../src/plugins", ".", "worker")
Ejemplo n.º 4
0
 def test_ssh_plugin_barrier(self):
     job_path = "sshbarrier_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.load(f, Loader=yaml.SafeLoader)
     commands = [[], []]
     init_plugins(jobconfig, commands, "../src/plugins", ".", "master")
     commands = [[], []]
     init_plugins(jobconfig, commands, "../src/plugins", ".", "worker")
Ejemplo n.º 5
0
 def test_ssh_plugin_barrier(self):
     job_path = "sshbarrier_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.safe_load(f)
     commands = [[], []]
     initializer.init_plugins(jobconfig, {}, {}, "", commands,
                              "../src/plugins", ".", "master")
     commands = [[], []]
     initializer.init_plugins(jobconfig, {}, {}, "", commands,
                              "../src/plugins", ".", "worker")
Ejemplo n.º 6
0
 def test_git_plugin(self):
     job_path = "git_repo_test_job.yaml"
     if os.path.exists(job_path):
         with open(job_path, 'rt') as f:
             jobconfig = yaml.safe_load(f)
     commands = [[], []]
     initializer.init_plugins(jobconfig, {}, {}, "", commands,
                              "../src/plugins", ".", "worker")
     repo_local_path = os.path.join(
         os.path.dirname(os.path.abspath(__file__)), "../src/code")
     self.assertTrue(os.path.exists(repo_local_path))
     shutil.rmtree(repo_local_path, onerror=self.on_remove_error)