'Startproject can use a project template from a tarball and create it in a specified location'

def test_custom_project_template_from_tarball_to_alternative_location(self):

    template_path = os.path.join(custom_templates_dir, u'project_template.tgz')
    args = [u'startproject', u'--template', template_path, u'tarballtestproject', u'altlocation']
    testproject_dir = os.path.join(test_dir, u'altlocation')
    os.mkdir(testproject_dir)
    self.addCleanup(shutil.rmtree, testproject_dir)
    (out, err) = self.run_django_admin(args)
    self.assertNoOutput(err)
    self.assertTrue(os.path.isdir(testproject_dir))
    self.assertTrue(os.path.exists(os.path.join(testproject_dir, u'run.py')))
