Ejemplo n.º 1
0
    def create_project(self, argv):
        parser = argparse.ArgumentParser(
            description='Create a new Halide project',
            usage='hlgen create project <name>')
        parser.add_argument('name', type=str,
                            help='The name of the project. This will also be the name of the directory created.')

        args = parser.parse_args(argv)

        project = Project.create_new(args.name)
        project.save()
 def __init__(self, test_case: TestProject):
     self.test_case = test_case
     project_name = test_case.id().split('.')[
         -1]  # due to https://stackoverflow.com/a/14954405/2137996
     self.project = Project.create_new(project_name)
     test_case.assertIsNotNone(self.project)