SERVER-92729 Ignore whitespace for commit message validation comparisons (#25191)
GitOrigin-RevId: 4b0e45da036e265971b82500736cdb0db4d8234a
This commit is contained in:
committed by
MongoDB Bot
parent
aa11c7f714
commit
bfa96e8503
@@ -59,6 +59,11 @@ class ValidateCommitMessageTest(unittest.TestCase):
|
||||
binsha=b"deadbeefdeadbeefdead",
|
||||
message="SERVER-123 asdf\nAnything in this description will be included in the commit message. Replace or delete this text before merging. Add links to testing in the comments of the PR.",
|
||||
), # Contains some banned strings
|
||||
Commit(
|
||||
repo=fake_repo,
|
||||
binsha=b"deadbeefdeadbeefdead",
|
||||
message="SERVER-123 asdf\nAnything\n\n in this description will be included in the commit message.\nReplace or delete this text before merging. Add links to testing in the\ncomments of the PR.",
|
||||
), # Contains some banned strings with extra newlines
|
||||
]
|
||||
|
||||
self.assertTrue(all(is_valid_commit(message) == False for message in messages))
|
||||
|
||||
Reference in New Issue
Block a user