From bc5f5e33d98ee266010faf0f04f2966623994cd7 Mon Sep 17 00:00:00 2001 From: Lars Kappert Date: Mon, 18 Apr 2022 12:21:55 -0300 Subject: [PATCH] Fix EOLs in specs --- test.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test.js b/test.js index d5c7b3c..51fa91a 100644 --- a/test.js +++ b/test.js @@ -66,9 +66,9 @@ const setup = () => { const date = /\([0-9]{4}-[0-9]{2}-[0-9]{2}\)/.source; const sha = /[0-9a-f]{7}/.source; const header = (from, to, version) => `# \\[${version || to}\\]\\(/compare/${from}...${to}\\) ${date}`; -const features = '\\n\\n\\n### Features\\n'; -const fixes = '\\n\\n\\n### Bug Fixes\\n'; -const commit = (type, name) => `\\n\\* \\*\\*${name}:\\*\\* ${type} ${name} ${sha}`; +const features = EOL + EOL + EOL + '### Features' + EOL; +const fixes = EOL + EOL + EOL + '### Bug Fixes' + EOL; +const commit = (type, name) => EOL + `\\* \\*\\*${name}:\\*\\* ${type} ${name} ${sha}`; test('should generate changelog using recommended bump (minor)', async () => { setup(); @@ -238,7 +238,7 @@ test(`should write and update infile`, async () => { add('fix', 'foo'); add('feat', 'bar'); - const h = 'The header\n\nThe subheader'; + const h = 'The header' + EOL + EOL + 'The subheader'; const infile = path.join(dir, 'CHANGES.md'); const [config, container] = getOptions({ preset, infile, header: h }); config.git.tag = true;