def test_delete(self): uut = GitProjectCheckout(self.git_url, self.checkouts_dir, "-project-", "-id-", "HEAD") uut.create() uut.delete() assert not exists(join(self.checkouts_dir, "-project-", "checkout")) assert not exists(uut.checkout_dir)
def test_create_copies_and_checks_out_repo(self): uut = GitProjectCheckout(self.git_url, self.checkouts_dir, "-project-", "-id-", "HEAD") uut.create() expected_checkout_path = join(self.checkouts_dir, "-project-", "-id-", "checkout") assert_equals(expected_checkout_path, uut.checkout_dir) assert exists(join(expected_checkout_path, ".git"))
def test_create_clones_repo(self): uut = GitProjectCheckout(self.git_url, self.checkouts_dir, "-project-", "-id-", "HEAD") uut.create() assert exists( join(self.checkouts_dir, "-project-", "checkout", ".git"))