Merge "Allow co-author email not to be included into angles"

This commit is contained in:
Jenkins 2014-09-26 13:36:34 +00:00 committed by Gerrit Code Review
commit 3a45b63073
2 changed files with 8 additions and 1 deletions

View File

@ -65,7 +65,8 @@ GIT_LOG_PATTERN = re.compile(''.join([(r[0] + ':(.*?)\n')
'diff_stat:' + DIFF_STAT_PATTERN,
re.DOTALL)
CO_AUTHOR_PATTERN_RAW = '(?P<author_name>.+?)\s*<(?P<author_email>.+)>'
CO_AUTHOR_PATTERN_RAW = ('(?P<author_name>.+?)\s*'
'<?(?P<author_email>[\w\.-]+@[\w\.-]+)>?')
CO_AUTHOR_PATTERN = re.compile(CO_AUTHOR_PATTERN_RAW, re.IGNORECASE)
MESSAGE_PATTERNS = {

View File

@ -112,6 +112,7 @@ message:Change-Id: Id811c762ec1d13992b306c4a38e7360575e61451
Co-Authored-By: Tupac Shakur <tupac.shakur@openstack.com>
Also-By: Bob Dylan <bob.dylan@openstack.com>
Also-By: Anonymous <wrong@email>
Also-By: Winnie the Pooh winnie222@openstack.org
diff_stat:
@ -159,3 +160,8 @@ diff_stat:
{'author_name': 'Bob Dylan',
'author_email': 'bob.dylan@openstack.com'},
commits[5]['coauthor'])
self.assertIn(
{'author_name': 'Winnie the Pooh',
'author_email': 'winnie222@openstack.org'},
commits[5]['coauthor'])