diff options
author | Ket3r <github@peter-kempter.de> | 2021-09-30 16:07:05 +0200 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2022-01-07 09:54:53 +0800 |
commit | cd8b9b2fd875b5040b1ca9f0c8f5acaffe70ab7f (patch) | |
tree | fbbc852b6ef46bf08fb0b36f7f6fb3733895e24e /test/test_commit.py | |
parent | edbf76f98f8430d711115f2c754de88e268e9303 (diff) | |
download | gitpython-cd8b9b2fd875b5040b1ca9f0c8f5acaffe70ab7f.tar.gz |
Use git interpret-trailers for trailers property
The whitespace handling and trailer selection isn't very trivial or good
documented. It therefore seemed easier and less error prone to just call
git to parse the message for the trailers section and remove superfluos
whitespaces.
Diffstat (limited to 'test/test_commit.py')
-rw-r--r-- | test/test_commit.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/test_commit.py b/test/test_commit.py index 5aeef2e6..40cf7dd2 100644 --- a/test/test_commit.py +++ b/test/test_commit.py @@ -435,14 +435,14 @@ JzJMZDRLQLFvnzqZuCjE KEY_1 = "Hello" VALUE_1 = "World" KEY_2 = "Key" - VALUE_2 = "Value" + VALUE_2 = "Value with inner spaces" # Check if KEY 1 & 2 with Value 1 & 2 is extracted from multiple msg variations msgs = [] msgs.append(f"Subject\n\n{KEY_1}: {VALUE_1}\n{KEY_2}: {VALUE_2}\n") msgs.append(f"Subject\n \nSome body of a function\n \n{KEY_1}: {VALUE_1}\n{KEY_2}: {VALUE_2}\n") msgs.append(f"Subject\n \nSome body of a function\n\nnon-key: non-value\n\n{KEY_1}: {VALUE_1}\n{KEY_2}: {VALUE_2}\n") - msgs.append(f"Subject\n \nSome multiline\n body of a function\n\nnon-key: non-value\n\n{KEY_1}: {VALUE_1}\n{KEY_2}: {VALUE_2}\n") + msgs.append(f"Subject\n \nSome multiline\n body of a function\n\nnon-key: non-value\n\n{KEY_1}: {VALUE_1}\n{KEY_2} : {VALUE_2}\n") for msg in msgs: commit = self.rorepo.commit('master') |