Commit 6fef1ab3 by Ben Straub

Tests should clean up after themselves

parent 7761ce21
......@@ -122,6 +122,8 @@ void test_core_env__0(void)
}
}
#endif
cl_fixture_cleanup(*val);
}
git_buf_free(&path);
......
......@@ -246,6 +246,7 @@ void test_index_tests__add(void)
git_index_free(index);
git_repository_free(repo);
cl_fixture_cleanup("myrepo");
}
void test_index_tests__add_from_workdir_to_a_bare_repository_returns_EBAREPO(void)
......
......@@ -33,6 +33,7 @@ void test_network_fetchlocal__complete(void)
git_strarray_free(&refnames);
git_remote_free(origin);
git_repository_free(repo);
cl_fixture_cleanup("foo");
}
void test_network_fetchlocal__partial(void)
......
......@@ -11,8 +11,13 @@ static git_repository *repo;
void test_odb_alternates__cleanup(void)
{
size_t i;
git_buf_free(&destpath);
git_buf_free(&filepath);
for (i=0; i<ARRAY_SIZE(paths); i++)
cl_fixture_cleanup(paths[i]);
}
static void init_linked_repo(const char *path, const char *alternate)
......
......@@ -446,6 +446,7 @@ void test_status_worktree__first_commit_in_progress(void)
git_index_free(index);
git_repository_free(repo);
cl_fixture_cleanup("getting_started");
}
......@@ -595,6 +596,7 @@ void test_status_worktree__bracket_in_filename(void)
git_index_free(index);
git_repository_free(repo);
cl_fixture_cleanup("with_bracket");
}
void test_status_worktree__space_in_filename(void)
......@@ -659,6 +661,7 @@ void test_status_worktree__space_in_filename(void)
git_index_free(index);
git_repository_free(repo);
cl_fixture_cleanup("with_space");
}
static const char *filemode_paths[] = {
......@@ -769,6 +772,7 @@ void test_status_worktree__disable_pathspec_match(void)
);
git_repository_free(repo);
cl_fixture_cleanup("pathspec");
}
......@@ -821,6 +825,7 @@ void test_status_worktree__new_staged_file_must_handle_crlf(void)
git_config_free(config);
git_index_free(index);
git_repository_free(repo);
cl_fixture_cleanup("getting_started");
}
void test_status_worktree__line_endings_dont_count_as_changes_with_autocrlf(void)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment