summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rw-r--r--t/helper/test-ref-store.c13
-rwxr-xr-xt/t1405-main-ref-store.sh8
-rwxr-xr-xt/t1406-submodule-ref-store.sh10
3 files changed, 3 insertions, 28 deletions
diff --git a/t/helper/test-ref-store.c b/t/helper/test-ref-store.c
index 759e69dc54..bba5f841c6 100644
--- a/t/helper/test-ref-store.c
+++ b/t/helper/test-ref-store.c
@@ -72,18 +72,6 @@ static int cmd_pack_refs(struct ref_store *refs, const char **argv)
return refs_pack_refs(refs, flags);
}
-static int cmd_peel_ref(struct ref_store *refs, const char **argv)
-{
- const char *refname = notnull(*argv++, "refname");
- struct object_id oid;
- int ret;
-
- ret = refs_peel_ref(refs, refname, &oid);
- if (!ret)
- puts(oid_to_hex(&oid));
- return ret;
-}
-
static int cmd_create_symref(struct ref_store *refs, const char **argv)
{
const char *refname = notnull(*argv++, "refname");
@@ -255,7 +243,6 @@ struct command {
static struct command commands[] = {
{ "pack-refs", cmd_pack_refs },
- { "peel-ref", cmd_peel_ref },
{ "create-symref", cmd_create_symref },
{ "delete-refs", cmd_delete_refs },
{ "rename-ref", cmd_rename_ref },
diff --git a/t/t1405-main-ref-store.sh b/t/t1405-main-ref-store.sh
index 74af927fba..5f69ef8519 100755
--- a/t/t1405-main-ref-store.sh
+++ b/t/t1405-main-ref-store.sh
@@ -14,13 +14,6 @@ test_expect_success 'pack_refs(PACK_REFS_ALL | PACK_REFS_PRUNE)' '
N=`find .git/refs -type f | wc -l`
'
-test_expect_success 'peel_ref(new-tag)' '
- git rev-parse HEAD >expected &&
- git tag -a -m new-tag new-tag HEAD &&
- $RUN peel-ref refs/tags/new-tag >actual &&
- test_cmp expected actual
-'
-
test_expect_success 'create_symref(FOO, refs/heads/master)' '
$RUN create-symref FOO refs/heads/master nothing &&
echo refs/heads/master >expected &&
@@ -29,6 +22,7 @@ test_expect_success 'create_symref(FOO, refs/heads/master)' '
'
test_expect_success 'delete_refs(FOO, refs/tags/new-tag)' '
+ git tag -a -m new-tag new-tag HEAD &&
git rev-parse FOO -- &&
git rev-parse refs/tags/new-tag -- &&
m=$(git rev-parse master) &&
diff --git a/t/t1406-submodule-ref-store.sh b/t/t1406-submodule-ref-store.sh
index 36b7ef5046..110ac40a98 100755
--- a/t/t1406-submodule-ref-store.sh
+++ b/t/t1406-submodule-ref-store.sh
@@ -11,7 +11,8 @@ test_expect_success 'setup' '
(
cd sub &&
test_commit first &&
- git checkout -b new-master
+ git checkout -b new-master &&
+ git tag -a -m new-tag new-tag HEAD
)
'
@@ -19,13 +20,6 @@ test_expect_success 'pack_refs() not allowed' '
test_must_fail $RUN pack-refs 3
'
-test_expect_success 'peel_ref(new-tag)' '
- git -C sub rev-parse HEAD >expected &&
- git -C sub tag -a -m new-tag new-tag HEAD &&
- $RUN peel-ref refs/tags/new-tag >actual &&
- test_cmp expected actual
-'
-
test_expect_success 'create_symref() not allowed' '
test_must_fail $RUN create-symref FOO refs/heads/master nothing
'