@@ -21,6 +21,20 @@ test("type with scope commit msg", () => {
21
21
expect ( cc . formatCommit ( "feat(cli): testing" ) ) . toBe ( "feat(cli): ✨ testing" )
22
22
} )
23
23
24
+ test ( "breaking changes" , ( ) => {
25
+ const cc = new ConventionalCommits ( new Devmoji ( new Config ( ) ) )
26
+ expect ( cc . formatCommit ( "feat(cli)!: important" ) ) . toBe (
27
+ "feat(cli)!: 💥 ✨ important"
28
+ )
29
+ } )
30
+
31
+ test ( "breaking changes multiline" , ( ) => {
32
+ const cc = new ConventionalCommits ( new Devmoji ( new Config ( ) ) )
33
+ expect (
34
+ cc . formatCommit ( "feat(cli): important\nBREAKING CHANGE: foo bar" )
35
+ ) . toBe ( "feat(cli): 💥 ✨ important\nBREAKING CHANGE: foo bar" )
36
+ } )
37
+
24
38
test ( "type with scope release commit msg" , ( ) => {
25
39
const cc = new ConventionalCommits ( new Devmoji ( new Config ( ) ) )
26
40
expect ( cc . formatCommit ( "chore(release): testing" ) ) . toBe (
@@ -36,7 +50,7 @@ test("type with scope release commit msg and devmoji", () => {
36
50
)
37
51
} )
38
52
39
- test ( "invalid commit msg " , ( ) => {
53
+ test ( "invalid commit msg" , ( ) => {
40
54
const cc = new ConventionalCommits ( new Devmoji ( new Config ( ) ) )
41
55
expect ( cc . formatCommit ( "invalid commit" ) ) . toBe ( "invalid commit" )
42
56
} )
@@ -66,7 +80,7 @@ chore(release): 🚀 deploy
66
80
eat(cli): 🚨 testing` )
67
81
} )
68
82
69
- test ( "should " , ( ) => {
83
+ test ( "should" , ( ) => {
70
84
const text =
71
85
"* 8f16492 - feat(cli): ✨ added cli for working with devmoji 🚀 (19 hours ago) <Folke Lemaitre>"
72
86
const cc = new ConventionalCommits ( new Devmoji ( new Config ( ) ) )
@@ -76,7 +90,7 @@ test("should ", () => {
76
90
)
77
91
} )
78
92
79
- test ( "multi log & commit " , ( ) => {
93
+ test ( "multi log & commit" , ( ) => {
80
94
const tests : [ string , string ] [ ] = [
81
95
[ "feat(foo): testing" , "feat(foo): :sparkles: testing" ] ,
82
96
[ "foo(security): testing" , "foo(security): :security: testing" ] ,
0 commit comments