From b41897a2b4b0c8de6176bb9134e45fe98ee5a1a5 Mon Sep 17 00:00:00 2001 From: "Fabien \"egg\" O'Carroll" Date: Mon, 17 Apr 2023 16:52:51 +0100 Subject: [PATCH] Fixed unit tests --- ghost/post-revisions/test/hello.test.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ghost/post-revisions/test/hello.test.js b/ghost/post-revisions/test/hello.test.js index 4f3d3a8fb1..315cadc172 100644 --- a/ghost/post-revisions/test/hello.test.js +++ b/ghost/post-revisions/test/hello.test.js @@ -93,7 +93,7 @@ describe('PostRevisions', function () { assert.deepEqual(actual, expected); }); - it('returns two revisions when there are no existing revisions', async function () { + it('returns one revisions when there are no existing revisions', async function () { const postRevisions = new PostRevisions({config}); const actual = await postRevisions.getRevisions({ @@ -106,9 +106,8 @@ describe('PostRevisions', function () { html: 'current' }, []); - assert.equal(actual.length, 2); - assert.equal(actual[0].lexical, 'previous'); - assert.equal(actual[1].lexical, 'current'); + assert.equal(actual.length, 1); + assert.equal(actual[0].lexical, 'current'); }); it('limits the number of revisions to the max_revisions count', async function () {