File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 8
8
from commitizen import cmd , exceptions , git
9
9
from pytest_mock import MockFixture
10
10
11
- from tests .utils import FakeCommand , create_file_and_commit
11
+ from tests .utils import FakeCommand , create_file_and_commit , create_tag
12
12
13
13
14
14
def test_git_object_eq ():
@@ -239,3 +239,13 @@ def test_eoltypes_get_eol_for_open():
239
239
assert git .EOLTypes .get_eol_for_open (git .EOLTypes .NATIVE ) == os .linesep
240
240
assert git .EOLTypes .get_eol_for_open (git .EOLTypes .LF ) == "\n "
241
241
assert git .EOLTypes .get_eol_for_open (git .EOLTypes .CRLF ) == "\r \n "
242
+
243
+
244
+ def test_create_tag_with_message (tmp_commitizen_project ):
245
+ with tmp_commitizen_project .as_cwd ():
246
+ create_file_and_commit ("feat(test): test" )
247
+ tag_name = "1.0"
248
+ tag_message = "test message"
249
+ create_tag (tag_name , tag_message )
250
+ assert git .get_latest_tag_name () == tag_name
251
+ assert git .get_tag_message (tag_name ) == f"'{ tag_message } '"
You can’t perform that action at this time.
0 commit comments