summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2017-05-12 09:09:07 +0200
committerPatrick Steinhardt <ps@pks.im>2017-06-06 09:38:44 +0200
commitfea0c81e95d5c22b758df6bedbd13321fa2ab195 (patch)
tree67c7c2143525088b292684edca54e936b43ae34f
parent064a60e96fc0ac134c9cba7b99bd31e1afbef886 (diff)
downloadlibgit2-fea0c81e95d5c22b758df6bedbd13321fa2ab195.tar.gz
tests: index::version: move up cleanup function
The init and cleanup functions for test suites are usually prepended to our actual tests. The index::version test suite does not adhere to this stile. Fix this.
-rw-r--r--tests/index/version.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/index/version.c b/tests/index/version.c
index 3fd240d3c..688a20f20 100644
--- a/tests/index/version.c
+++ b/tests/index/version.c
@@ -3,6 +3,12 @@
static git_repository *g_repo = NULL;
+void test_index_version__cleanup(void)
+{
+ cl_git_sandbox_cleanup();
+ g_repo = NULL;
+}
+
void test_index_version__can_write_v4(void)
{
git_index *index;
@@ -33,9 +39,3 @@ void test_index_version__can_write_v4(void)
git_index_free(index);
}
-
-void test_index_version__cleanup(void)
-{
- cl_git_sandbox_cleanup();
- g_repo = NULL;
-}