Skip to content

Commit 9722ab2

Browse files
committed
test: Fix tests using a commit format starting with #
`[email protected]` consider subject starting with `#` as comments See conventional-changelog/conventional-changelog#251
1 parent 302f9f7 commit 9722ab2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/integration.test.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,11 +50,11 @@ test('Accept "config" option', async t => {
5050

5151
test('Accept a "parseOpts" object as option', async t => {
5252
const commits = [
53-
{message: '##BUGFIX## First fix (fixes #123)'},
54-
{message: '##FEATURE## Second feature (fixes #456)'},
53+
{message: '%%BUGFIX%% First fix (fixes #123)'},
54+
{message: '%%FEATURE%% Second feature (fixes #456)'},
5555
];
5656
const releaseType = await promisify(commitAnalyzer)(
57-
{parserOpts: {headerPattern: /^##(.*?)## (.*)$/, headerCorrespondence: ['tag', 'shortDesc']}},
57+
{parserOpts: {headerPattern: /^%%(.*?)%% (.*)$/, headerCorrespondence: ['tag', 'shortDesc']}},
5858
{commits, logger: t.context.logger}
5959
);
6060

@@ -67,11 +67,11 @@ test('Accept a "parseOpts" object as option', async t => {
6767
});
6868

6969
test('Accept a partial "parseOpts" object as option', async t => {
70-
const commits = [{message: '##fix## First fix (fixes #123)'}, {message: '##Update## Second feature (fixes #456)'}];
70+
const commits = [{message: '%%fix%% First fix (fixes #123)'}, {message: '%%Update%% Second feature (fixes #456)'}];
7171
const releaseType = await promisify(commitAnalyzer)(
7272
{
7373
config: 'conventional-changelog-eslint',
74-
parserOpts: {headerPattern: /^##(.*?)## (.*)$/, headerCorrespondence: ['type', 'shortDesc']},
74+
parserOpts: {headerPattern: /^%%(.*?)%% (.*)$/, headerCorrespondence: ['type', 'shortDesc']},
7575
},
7676
{commits, logger: t.context.logger}
7777
);

0 commit comments

Comments
 (0)