Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
git2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
git2
Commits
b52b6571
Commit
b52b6571
authored
Sep 22, 2012
by
nulltoken
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
branch: enhance branch moving test coverage
parent
096d9e94
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
tests-clar/refs/branches/move.c
+13
-0
No files found.
tests-clar/refs/branches/move.c
View file @
b52b6571
...
...
@@ -62,3 +62,16 @@ void test_refs_branches_move__can_force_move_over_an_existing_branch(void)
{
cl_git_pass
(
git_branch_move
(
ref
,
"master"
,
1
));
}
void
test_refs_branches_move__moving_the_branch_pointed_at_by_HEAD_updates_HEAD
(
void
)
{
git_reference
*
branch
;
cl_git_pass
(
git_reference_lookup
(
&
branch
,
repo
,
"refs/heads/master"
));
cl_git_pass
(
git_branch_move
(
branch
,
"master2"
,
0
));
git_reference_free
(
branch
);
cl_git_pass
(
git_repository_head
(
&
branch
,
repo
));
cl_assert_equal_s
(
"refs/heads/master2"
,
git_reference_name
(
branch
));
git_reference_free
(
branch
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment