Show 18 quoted lines
> @@ builtin/refs.c: static int cmd_refs_optimize(int argc, const char **argv, const
> + if (repo_get_oid_with_flags(repo, argv[1], &newoid, GET_OID_SKIP_AMBIGUITY_CHECK))
> + die(_("invalid object ID: '%s'"), argv[1]);
> + if (is_null_oid(&newoid))
> -+ die(_("cannot create reference with null old object ID"));
> ++ die(_("cannot create reference with null new object ID"));
> +
> + ret = refs_update_ref(get_main_ref_store(repo), message, refname,
> + &newoid, null_oid(repo->hash_algo), flags,
> @@ t/t1466-refs-create.sh (new)
> + (
> + cd repo &&
> + test_must_fail git refs create refs/heads/foo $ZERO_OID 2>err &&
> -+ test_grep "null old object ID" err &&
> ++ test_grep "null new object ID" err &&
> + test_must_fail git refs exists refs/heads/foo
> + )
> +'