def run_flextglgen(self, template_dir=None): args = Empty() args.download = False args.outdir = os.path.join(self.path, 'generated') args.template_dir = template_dir if template_dir else self.path flextGLgen.main('-D generated -t somepath profile.txt', args, os.path.join(self.path, 'profile.txt'))
def test_out(self): with self.assertRaises(SystemExit): args = Empty() args.download = False args.outdir = os.path.join(self.cwd, 'profile.txt') args.template_dir = os.path.join(self.root, 'templates') flextGLgen.main('', args, os.path.join(self.cwd, 'profile.txt'))
def test_template(self): with self.assertRaises(SystemExit): args = Empty() args.download = False args.outdir = os.path.join(self.path, 'generated') args.template_dir = os.path.join(self.cwd, 'nonexistent') flextGLgen.main('', args, os.path.join(self.cwd, 'profile.txt'))
def run_flextglgen(self, profile): args = Empty() args.download = False args.outdir = os.path.join(self.path, 'generated') args.template_dir = os.path.join( self.root, 'templates', self.template) if self.template else self.path flextGLgen.main('-D generated -t somepath ' + profile, args, os.path.join(self.cwd, profile))
def run_flextglgen(self, profile): args = Empty() args.download = False args.outdir = os.path.join(self.cwd, 'generated') args.template = 'glfw' flextGLgen.main('', args, os.path.join(self.cwd, profile))
def run_flextglgen(self, profile): args = Empty() args.download = False args.outdir = os.path.join(self.path, 'generated') args.template_dir = os.path.join(self.root, 'templates', self.template) if self.template else self.path flextGLgen.main(args, os.path.join(self.cwd, profile))
def run_flextglgen(self, profile): args = Empty() args.download = False args.outdir = os.path.join(self.cwd, 'generated') args.template = 'glfw' flextGLgen.main(args, os.path.join(self.cwd, profile))