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
19579847
Commit
19579847
authored
May 08, 2012
by
Russell Belfer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clean up warnings and tests
parent
2c0cdc3a
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
6 deletions
+9
-6
src/posix.c
+1
-1
tests-clar/object/lookup.c
+6
-4
tests-clar/status/worktree.c
+2
-1
No files found.
src/posix.c
View file @
19579847
...
...
@@ -21,7 +21,7 @@ int p_open(const char *path, int flags, ...)
va_list
arg_list
;
va_start
(
arg_list
,
flags
);
mode
=
va_arg
(
arg_list
,
mode_
t
);
mode
=
(
mode_t
)
va_arg
(
arg_list
,
in
t
);
va_end
(
arg_list
);
}
...
...
tests-clar/object/lookup.c
View file @
19579847
...
...
@@ -14,22 +14,24 @@ void test_object_lookup__cleanup(void)
git_repository_free
(
g_repo
);
}
void
test_object_lookup__look
ing_up_an_exisiting_object_by_its_wrong_type_returns_ENOTFOUND
(
void
)
void
test_object_lookup__look
up_wrong_type_returns_enotfound
(
void
)
{
const
char
*
commit
=
"e90810b8df3e80c413d903f631643c716887138d"
;
git_oid
oid
;
git_object
*
object
;
cl_git_pass
(
git_oid_fromstr
(
&
oid
,
commit
));
cl_assert_equal_i
(
GIT_ENOTFOUND
,
git_object_lookup
(
&
object
,
g_repo
,
&
oid
,
GIT_OBJ_TAG
));
cl_assert_equal_i
(
GIT_ENOTFOUND
,
git_object_lookup
(
&
object
,
g_repo
,
&
oid
,
GIT_OBJ_TAG
));
}
void
test_object_lookup__look
ing_up_a_non_exisiting_object_returns_ENOTFOUND
(
void
)
void
test_object_lookup__look
up_nonexisting_returns_enotfound
(
void
)
{
const
char
*
unknown
=
"deadbeefdeadbeefdeadbeefdeadbeefdeadbeef"
;
git_oid
oid
;
git_object
*
object
;
cl_git_pass
(
git_oid_fromstr
(
&
oid
,
unknown
));
cl_assert_equal_i
(
GIT_ENOTFOUND
,
git_object_lookup
(
&
object
,
g_repo
,
&
oid
,
GIT_OBJ_ANY
));
cl_assert_equal_i
(
GIT_ENOTFOUND
,
git_object_lookup
(
&
object
,
g_repo
,
&
oid
,
GIT_OBJ_ANY
));
}
tests-clar/status/worktree.c
View file @
19579847
...
...
@@ -389,7 +389,8 @@ void test_status_worktree__issue_592_5(void)
void
test_status_worktree__cannot_retrieve_the_status_of_a_bare_repository
(
void
)
{
git_repository
*
repo
;
int
error
,
status
=
0
;
int
error
;
unsigned
int
status
=
0
;
cl_git_pass
(
git_repository_open
(
&
repo
,
cl_fixture
(
"testrepo.git"
)));
...
...
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