Skip to content

Commit

Permalink
test: more
Browse files Browse the repository at this point in the history
  • Loading branch information
hyoban committed Feb 17, 2024
1 parent d5a9dda commit 9a3bd69
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/getCommitMeaning.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,20 @@ describe("getCommitMeaning", () => {
"chore: deps\n\nMultiple: footer notes\nMultiple: footer notes",
{ type: "chore" },
],
// This test may should be { type: "chore" },
// but conventionalCommitsParser looks like can't parse this case correctly
[
"chore: deps\n\nBREAKING CHANGE line starts with BREAKING CHANGE (no :)",
"meaningful",
],
[
"chore: deps\n\nline contains BREAKING CHANGE: inside it",
{ type: "chore" },
],
[
"BREAKING CHANGE (major): line starts with something like BREAKING CHANGE",
{ type: undefined },
],
])("returns %j for %s", (input, expected) => {
expect(getCommitMeaning(input)).toEqual(expected);
});
Expand Down

0 comments on commit 9a3bd69

Please sign in to comment.