def test_create_pipeline(self): self.assertEqual(os.listdir(self.path), []) creator.create_pipeline(self.pipeline_path) expected = ['in_corral.py', 'example'] self.assertCountEqual(os.listdir(self.container_path), expected) self.assertTrue(os.path.isdir(self.pipeline_path)) manager_path = os.path.join(self.container_path, "in_corral.py") self.assertTrue(os.path.isfile(manager_path))
def test_create_pipeline(self): self.assertEqual(os.listdir(self.path), []) creator.create_pipeline(self.pipeline_path) expected = ['in_corral.py', 'pipeline'] self.assertCountEqual(os.listdir(self.path), expected) self.assertTrue(os.path.isdir(self.pipeline_path)) manager_path = os.path.join(self.path, "in_corral.py") self.assertTrue(os.path.isfile(manager_path)) template_basenames = [ e for e, _ in creator.TEMPLATES if e != "in_corral.py"] self.assertCountEqual( os.listdir(self.pipeline_path), template_basenames)
def test_create_pipeline(self): self.assertEqual(os.listdir(self.path), []) creator.create_pipeline(self.pipeline_path) expected = ['in_corral.py', 'pipeline'] self.assertCountEqual(os.listdir(self.path), expected) self.assertTrue(os.path.isdir(self.pipeline_path)) manager_path = os.path.join(self.path, "in_corral.py") self.assertTrue(os.path.isfile(manager_path)) template_basenames = [ e for e, _ in creator.TEMPLATES if e != "in_corral.py" ] self.assertCountEqual(os.listdir(self.pipeline_path), template_basenames)
def test_directory_exists_failure(self): with self.assertRaises(ValidationError): creator.create_pipeline(self.path)