summaryrefslogtreecommitdiff
path: root/tests/repo/state.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/repo/state.c')
-rw-r--r--tests/repo/state.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/repo/state.c b/tests/repo/state.c
index bf2633c17..7f20eebe8 100644
--- a/tests/repo/state.c
+++ b/tests/repo/state.c
@@ -57,6 +57,15 @@ void test_repo_state__revert(void)
assert_repo_state(GIT_REPOSITORY_STATE_NONE);
}
+void test_repo_state__revert_sequence(void)
+{
+ setup_simple_state(GIT_REVERT_HEAD_FILE);
+ setup_simple_state(GIT_SEQUENCER_TODO_FILE);
+ assert_repo_state(GIT_REPOSITORY_STATE_REVERT_SEQUENCE);
+ cl_git_pass(git_repository_state_cleanup(_repo));
+ assert_repo_state(GIT_REPOSITORY_STATE_NONE);
+}
+
void test_repo_state__cherry_pick(void)
{
setup_simple_state(GIT_CHERRYPICK_HEAD_FILE);
@@ -65,6 +74,15 @@ void test_repo_state__cherry_pick(void)
assert_repo_state(GIT_REPOSITORY_STATE_NONE);
}
+void test_repo_state__cherrypick_sequence(void)
+{
+ setup_simple_state(GIT_CHERRYPICK_HEAD_FILE);
+ setup_simple_state(GIT_SEQUENCER_TODO_FILE);
+ assert_repo_state(GIT_REPOSITORY_STATE_CHERRYPICK_SEQUENCE);
+ cl_git_pass(git_repository_state_cleanup(_repo));
+ assert_repo_state(GIT_REPOSITORY_STATE_NONE);
+}
+
void test_repo_state__bisect(void)
{
setup_simple_state(GIT_BISECT_LOG_FILE);