From d35274e17cb807b8f9365cb4b3766198443c7efa Mon Sep 17 00:00:00 2001 From: mobeicanyue <81098819+mobeicanyue@users.noreply.github.com> Date: Tue, 20 Feb 2024 18:58:14 +0800 Subject: [PATCH 1/2] Fix typos --- test/scripts/helpers/css.js | 2 +- test/scripts/helpers/full_url_for.js | 2 +- test/scripts/helpers/js.js | 2 +- test/scripts/helpers/list_archives.js | 6 +++--- test/scripts/helpers/url_for.js | 2 +- test/scripts/hexo/hexo.js | 2 +- test/scripts/hexo/post.js | 6 +++--- test/scripts/processors/asset.js | 2 +- test/scripts/tags/full_url_for.js | 2 +- test/scripts/tags/url_for.js | 2 +- 10 files changed, 14 insertions(+), 14 deletions(-) diff --git a/test/scripts/helpers/css.js b/test/scripts/helpers/css.js index 6241ff93fd..21eb15bd50 100644 --- a/test/scripts/helpers/css.js +++ b/test/scripts/helpers/css.js @@ -62,7 +62,7 @@ describe('css', () => { assertResult(css({href: '/script.css', foo: 'bar'}), {href: '/script.css', foo: 'bar'}); }); - it('mulitple objects', () => { + it('multiple objects', () => { assertResult(css({href: '/foo.css'}, {href: '/bar.css'}), [{href: '/foo.css'}, {href: '/bar.css'}]); assertResult(css({href: '/aaa.css', bbb: 'ccc'}, {href: '/ddd.css', eee: 'fff'}), [{href: '/aaa.css', bbb: 'ccc'}, {href: '/ddd.css', eee: 'fff'}]); diff --git a/test/scripts/helpers/full_url_for.js b/test/scripts/helpers/full_url_for.js index 313de00273..f84653db00 100755 --- a/test/scripts/helpers/full_url_for.js +++ b/test/scripts/helpers/full_url_for.js @@ -17,7 +17,7 @@ describe('full_url_for', () => { fullUrlFor('/index.html').should.eql(ctx.config.url + '/index.html'); }); - it('internel url (pretty_urls.trailing_index disabled)', () => { + it('internal url (pretty_urls.trailing_index disabled)', () => { ctx.config.pretty_urls = { trailing_index: false }; fullUrlFor('index.html').should.eql(ctx.config.url + '/'); fullUrlFor('/index.html').should.eql(ctx.config.url + '/'); diff --git a/test/scripts/helpers/js.js b/test/scripts/helpers/js.js index 22a23805b1..89cfad5b6c 100644 --- a/test/scripts/helpers/js.js +++ b/test/scripts/helpers/js.js @@ -66,7 +66,7 @@ describe('js', () => { assertResult(js({src: '/script.js', foo: 'bar'}), {src: '/script.js', foo: 'bar'}); }); - it('mulitple objects', () => { + it('multiple objects', () => { assertResult(js({src: '/foo.js'}, {src: '/bar.js'}), [{src: '/foo.js'}, {src: '/bar.js'}]); assertResult(js({src: '/aaa.js', bbb: 'ccc'}, {src: '/ddd.js', eee: 'fff'}), [{src: '/aaa.js', bbb: 'ccc'}, {src: '/ddd.js', eee: 'fff'}]); diff --git a/test/scripts/helpers/list_archives.js b/test/scripts/helpers/list_archives.js index b733a60c6c..10d613e434 100644 --- a/test/scripts/helpers/list_archives.js +++ b/test/scripts/helpers/list_archives.js @@ -199,9 +199,9 @@ describe('list_archives', () => { result.should.eql([ '' ].join('')); }); diff --git a/test/scripts/helpers/url_for.js b/test/scripts/helpers/url_for.js index 8f953a7d10..4f84e7153b 100644 --- a/test/scripts/helpers/url_for.js +++ b/test/scripts/helpers/url_for.js @@ -50,7 +50,7 @@ describe('url_for', () => { ctx.config.relative_link = false; }); - it('internel url (pretty_urls.trailing_index disabled)', () => { + it('internal url (pretty_urls.trailing_index disabled)', () => { ctx.config.pretty_urls = { trailing_index: false }; ctx.path = ''; ctx.config.root = '/'; diff --git a/test/scripts/hexo/hexo.js b/test/scripts/hexo/hexo.js index b039ec1fb0..181f324fda 100644 --- a/test/scripts/hexo/hexo.js +++ b/test/scripts/hexo/hexo.js @@ -70,7 +70,7 @@ describe('Hexo', () => { hexo.config_path.should.eql(join(__dirname, '_config.yml')); }); - it('constructs mutli-config', () => { + it('constructs multi-config', () => { const configs = ['../../../fixtures/_config.json', '../../../fixtures/_config.json']; const args = { _: [], config: configs.join(',') }; const hexo = new Hexo(base_dir, args); diff --git a/test/scripts/hexo/post.js b/test/scripts/hexo/post.js index 109bf2367b..890a62b541 100644 --- a/test/scripts/hexo/post.js +++ b/test/scripts/hexo/post.js @@ -1371,7 +1371,7 @@ describe('Post', () => { }); // https://github.com/hexojs/hexo/issues/5301 - it('render() - dont escape uncomplete tags', async () => { + it('render() - dont escape incomplete tags', async () => { const content = 'dont drop `{% }` 11111 `{# }` 22222 `{{ }` 33333'; const data = await post.render(null, { @@ -1385,8 +1385,8 @@ describe('Post', () => { data.content.should.not.contains('`'); // ` }); - it('render() - uncomplete tags throw error', async () => { - const content = 'nunjucks should thorw {# } error'; + it('render() - incomplete tags throw error', async () => { + const content = 'nunjucks should throw {# } error'; try { await post.render(null, { diff --git a/test/scripts/processors/asset.js b/test/scripts/processors/asset.js index 2a268714c3..673dec29bd 100644 --- a/test/scripts/processors/asset.js +++ b/test/scripts/processors/asset.js @@ -93,7 +93,7 @@ describe('asset', () => { ]); }); - it('asset - type: create (when source path is configed to parent directory)', async () => { + it('asset - type: create (when source path is configured to parent directory)', async () => { const file = newFile({ path: '../../source/foo.jpg', type: 'create', diff --git a/test/scripts/tags/full_url_for.js b/test/scripts/tags/full_url_for.js index ea01912392..05a8d4929e 100644 --- a/test/scripts/tags/full_url_for.js +++ b/test/scripts/tags/full_url_for.js @@ -30,7 +30,7 @@ describe('full_url_for', () => { $('a').html().should.eql('index'); }); - it('internel url (pretty_urls.trailing_index disabled)', () => { + it('internal url (pretty_urls.trailing_index disabled)', () => { ctx.config.pretty_urls = { trailing_index: false }; let $ = cheerio.load(fullUrlFor('index index.html')); $('a').attr('href').should.eql(ctx.config.url + '/'); diff --git a/test/scripts/tags/url_for.js b/test/scripts/tags/url_for.js index 1b905df59a..4fe9d38fcc 100644 --- a/test/scripts/tags/url_for.js +++ b/test/scripts/tags/url_for.js @@ -80,7 +80,7 @@ describe('url_for', () => { ctx.config.relative_link = false; }); - it('internel url (pretty_urls.trailing_index disabled)', () => { + it('internal url (pretty_urls.trailing_index disabled)', () => { ctx.config.pretty_urls = { trailing_index: false }; ctx.path = ''; ctx.config.root = '/'; From cf63b2222b28b65da60f0500b854aebad3b051b6 Mon Sep 17 00:00:00 2001 From: mobeicanyue <81098819+mobeicanyue@users.noreply.github.com> Date: Wed, 21 Feb 2024 13:13:14 +0800 Subject: [PATCH 2/2] Update list_archives.js --- test/scripts/helpers/list_archives.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/scripts/helpers/list_archives.js b/test/scripts/helpers/list_archives.js index 10d613e434..b733a60c6c 100644 --- a/test/scripts/helpers/list_archives.js +++ b/test/scripts/helpers/list_archives.js @@ -199,9 +199,9 @@ describe('list_archives', () => { result.should.eql([ '' ].join('')); });