File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 154
154
refute_line --partial " Limit the subject line to 50 characters"
155
155
}
156
156
157
+ @test " validation: ignores tag: prefix when checking subject line length" {
158
+ echo " n" > $FAKE_TTY
159
+ run git commit -m " tag: Add foo bar string to my_file"
160
+
161
+ assert_success
162
+ refute_line --partial " Limit the subject line to 50 characters"
163
+ }
164
+ @test " validation: ignores [<tag>] prefix when checking subject line length" {
165
+ echo " n" > $FAKE_TTY
166
+ run git commit -m " [tag] Add foo bar string to my_file"
167
+
168
+ assert_success
169
+ refute_line --partial " Limit the subject line to 50 characters"
170
+ }
171
+ @test " validation: ignores {<tag>} prefix when checking subject line length" {
172
+ echo " n" > $FAKE_TTY
173
+ run git commit -m " {tag} Add foo bar string to my_file"
174
+
175
+ assert_success
176
+ refute_line --partial " Limit the subject line to 50 characters"
177
+ }
178
+
157
179
# 3. Capitalize the subject line
158
180
# ------------------------------------------------------------------------------
159
181
You can’t perform that action at this time.
0 commit comments