@@ -36,7 +36,7 @@ def test_user_commit_summary_get_comment_body(self) -> None:
3636 m = UserCommitSummary (
"some_other_sha" ,
123456 ,
'login_value2' ,
'author name2' ,
'[email protected] ' ,
False ,
False )
3737 missing = [m ]
3838
39- body = get_comment_body ('github' , 'https://foo.com' , signed , missing )
39+ body = get_comment_body ('github' , 'https://foo.com' , signed , missing , False )
4040 self .assertTrue (':white_check_mark:' in body )
4141 self .assertTrue (':x:' in body )
4242
@@ -47,7 +47,7 @@ def test_user_commit_summary_tag_not_in_get_comment_body(self) -> None:
4747
4848 missing = []
4949
50- body = get_comment_body ('github' , 'https://foo.com' , signed , missing )
50+ body = get_comment_body ('github' , 'https://foo.com' , signed , missing , False )
5151 self .assertTrue (':white_check_mark:' in body )
5252 self .assertTrue ('login_value' in body )
5353 self .assertFalse ('@login_value' in body ) # users should not be tagged in signed use case
@@ -58,6 +58,19 @@ def test_user_commit_summary_tag_in_get_comment_body(self) -> None:
5858 m = UserCommitSummary (
"some_other_sha" ,
123456 ,
'login_value2' ,
'author name2' ,
'[email protected] ' ,
False ,
False )
5959 missing = [m ]
6060
61- body = get_comment_body ('github' , 'https://foo.com' , signed , missing )
61+ body = get_comment_body ('github' , 'https://foo.com' , signed , missing , False )
6262 self .assertTrue (':x:' in body )
6363 self .assertTrue ('@login_value2' in body ) # users should be tagged in missing use case
64+
65+ def test_user_commit_summary_get_comment_body_missing_co_authors (self ) -> None :
66+ s1 = UserCommitSummary (
"abc1234xyz-123" ,
1234 ,
'login_value' ,
'author name' ,
'[email protected] ' ,
True ,
True )
67+ s2 = UserCommitSummary (
"abc1234xyz-456" ,
1234 ,
'login_value' ,
'author name' ,
'[email protected] ' ,
True ,
True )
68+ signed = [s1 , s2 ]
69+
70+ m = UserCommitSummary (
"some_other_sha" ,
123456 ,
'login_value2' ,
'author name2' ,
'[email protected] ' ,
False ,
False )
71+ missing = [m ]
72+
73+ body = get_comment_body ('github' , 'https://foo.com' , signed , missing , True )
74+ self .assertTrue (':white_check_mark:' in body )
75+ self .assertTrue (':x:' in body )
76+ self .assertTrue ('One or more co-authors of this pull request were not found' in body )
0 commit comments