summaryrefslogtreecommitdiff
path: root/tests-clar/reset/soft.c
diff options
context:
space:
mode:
authorCarlos Martín Nieto <cmn@dwim.me>2013-09-17 09:50:30 +0200
committerCarlos Martín Nieto <cmn@dwim.me>2013-09-17 09:50:30 +0200
commit605da51a2cfd86901b6fa5f9cf71111a63ab4418 (patch)
treedbe23d26a4cbd93d457c68fdec7b4b10605314ac /tests-clar/reset/soft.c
parentc62b5ca590fb2f1743f43439b04159b168a36dda (diff)
downloadlibgit2-605da51a2cfd86901b6fa5f9cf71111a63ab4418.tar.gz
No such thing as an orphan branch
Unfortunately git-core uses the term "unborn branch" and "orphan branch" interchangeably. However, "orphan" is only really there for the checkout command, which has the `--orphan` option so it doesn't actually create the branch. Branches never have parents, so the distinction of a branch with no parents is odd to begin with. Crucially, the error messages deal with unborn branches, so let's use that.
Diffstat (limited to 'tests-clar/reset/soft.c')
-rw-r--r--tests-clar/reset/soft.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests-clar/reset/soft.c b/tests-clar/reset/soft.c
index 884697c91..bd6fcc205 100644
--- a/tests-clar/reset/soft.c
+++ b/tests-clar/reset/soft.c
@@ -95,19 +95,19 @@ void test_reset_soft__cannot_reset_to_a_tag_not_pointing_at_a_commit(void)
cl_git_fail(git_reset(repo, target, GIT_RESET_SOFT));
}
-void test_reset_soft__resetting_against_an_orphaned_head_repo_makes_the_head_no_longer_orphaned(void)
+void test_reset_soft__resetting_against_an_unborn_head_repo_makes_the_head_no_longer_unborn(void)
{
git_reference *head;
retrieve_target_from_oid(&target, repo, KNOWN_COMMIT_IN_BARE_REPO);
- make_head_orphaned(repo, NON_EXISTING_HEAD);
+ make_head_unborn(repo, NON_EXISTING_HEAD);
- cl_assert_equal_i(true, git_repository_head_orphan(repo));
+ cl_assert_equal_i(true, git_repository_head_unborn(repo));
cl_git_pass(git_reset(repo, target, GIT_RESET_SOFT));
- cl_assert_equal_i(false, git_repository_head_orphan(repo));
+ cl_assert_equal_i(false, git_repository_head_unborn(repo));
cl_git_pass(git_reference_lookup(&head, repo, NON_EXISTING_HEAD));
cl_assert_equal_i(0, git_oid_streq(git_reference_target(head), KNOWN_COMMIT_IN_BARE_REPO));