Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Douglas
erp5
Commits
f35be15d
Commit
f35be15d
authored
Dec 14, 2012
by
Sebastien Robin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use git configuration instead of passing author in parameters
parent
14da52c3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
erp5/tests/testERP5TestNode.py
erp5/tests/testERP5TestNode.py
+10
-3
No files found.
erp5/tests/testERP5TestNode.py
View file @
f35be15d
...
...
@@ -105,13 +105,20 @@ class ERP5TestNode(TestCase):
for
i
,
repository_path
in
enumerate
(
repository_list
):
call
=
self
.
getCaller
(
cwd
=
repository_path
)
call
(
"git init"
.
split
())
git_config
=
open
(
os
.
path
.
join
(
repository_path
,
'.git'
,
'config'
),
'a'
)
git_config
.
write
(
"""
[user]
name = a b
email = a@b.c
"""
)
git_config
.
close
()
call
(
"touch first_file"
.
split
())
call
(
"git add first_file"
.
split
())
call
(
"git commit -v -m first_commit"
.
split
()
+
[
'--author="a b <a@b.c>"'
]
)
call
(
"git commit -v -m first_commit"
.
split
())
my_file
=
open
(
os
.
path
.
join
(
repository_path
,
'first_file'
),
'w'
)
my_file
.
write
(
"initial_content%i"
%
i
)
my_file
.
close
()
call
(
"git commit -av -m next_commit"
.
split
()
+
[
'--author="a b <a@b.c>"'
]
)
call
(
"git commit -av -m next_commit"
.
split
())
output
=
call
([
'git'
,
'log'
,
'--format=%H %s'
])
output_line_list
=
output
.
split
(
"
\
n
"
)
self
.
assertEquals
(
3
,
len
(
output_line_list
))
...
...
@@ -211,7 +218,7 @@ branch = foo
my_file
.
write
(
"next_content"
)
my_file
.
close
()
call
=
self
.
getCaller
(
cwd
=
self
.
remote_repository1
)
call
(
"git commit -av -m new_commit"
.
split
()
+
[
'--author="a b <a@b.c>"'
]
)
call
(
"git commit -av -m new_commit"
.
split
())
rev_list
=
test_node
.
getAndUpdateFullRevisionList
(
node_test_suite
)
self
.
assertTrue
(
rev_list
[
0
].
startswith
(
'rep0=2-'
))
self
.
assertTrue
(
rev_list
[
1
].
startswith
(
'rep1=3-'
))
...
...
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