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
cfc17dc4
Commit
cfc17dc4
authored
Jun 09, 2012
by
Adam Roben
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a test showing that git_status_file gets confused by spaces in .gitignore
parent
e0b110ed
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
tests-clar/status/ignore.c
+14
-0
No files found.
tests-clar/status/ignore.c
View file @
cfc17dc4
...
...
@@ -131,3 +131,17 @@ void test_status_ignore__empty_repo_with_gitignore_rewrite(void)
cl_assert
(
ignored
);
}
void
test_status_ignore__ignore_pattern_contains_space
(
void
)
{
unsigned
int
flags
;
const
mode_t
mode
=
0777
;
g_repo
=
cl_git_sandbox_init
(
"empty_standard_repo"
);
cl_git_rewritefile
(
"empty_standard_repo/.gitignore"
,
"foo bar.txt
\n
"
);
cl_git_pass
(
git_futils_mkdir_r
(
"empty_standard_repo/foo"
,
NULL
,
mode
));
cl_git_mkfile
(
"empty_standard_repo/foo/look-ma.txt"
,
"I'm not going to be ignored!"
);
cl_git_pass
(
git_status_file
(
&
flags
,
g_repo
,
"foo/look-ma.txt"
));
cl_assert
(
flags
==
GIT_STATUS_WT_NEW
);
}
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