Skip to content

Commit 3e500fc

Browse files
Carson HowardCarson Howard
authored andcommitted
test: submodule: add: join path without slashes
1 parent 0a74f39 commit 3e500fc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/submodule/add.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,8 @@ void test_submodule_add__path_exists_in_index(void)
140140
/* In this repo, HEAD (master) has no remote tracking branc h*/
141141
g_repo = cl_git_sandbox_init("testrepo");
142142

143-
git_buf_joinpath(&dirname, git_repository_workdir(g_repo), "/TestGitRepository");
144-
git_buf_joinpath(&filename, dirname.ptr, "/test.txt");
143+
git_buf_joinpath(&dirname, git_repository_workdir(g_repo), "TestGitRepository");
144+
git_buf_joinpath(&filename, dirname.ptr, "test.txt");
145145

146146
p_mkdir(dirname.ptr, 0700);
147147
fd = fopen(filename.ptr, "w");
@@ -174,7 +174,7 @@ void test_submodule_add__file_exists_in_index(void)
174174
/* In this repo, HEAD (master) has no remote tracking branc h*/
175175
g_repo = cl_git_sandbox_init("testrepo");
176176

177-
git_buf_joinpath(&name, git_repository_workdir(g_repo), "/TestGitRepository");
177+
git_buf_joinpath(&name, git_repository_workdir(g_repo), "TestGitRepository");
178178

179179
fd = fopen(name.ptr, "w");
180180
fclose(fd);

0 commit comments

Comments
 (0)