From ca39999daf1ee488c4570f6f19f27b30d815f8b5 Mon Sep 17 00:00:00 2001 From: Sarah Schneider Date: Thu, 3 Dec 2020 12:55:57 -0500 Subject: [PATCH] update hidden page expectations --- tests/rendering/server.js | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/rendering/server.js b/tests/rendering/server.js index c3aea43a41..02cd336bab 100644 --- a/tests/rendering/server.js +++ b/tests/rendering/server.js @@ -369,9 +369,12 @@ describe('server', () => { done() }) + test('exist in the set of English pages', async () => { + expect(hiddenPages.length).toBeGreaterThan(0) + }) + test('are listed at /early-access', async () => { - // hiddenPages count multiplied by product version count per page - expect(hiddenPageHrefs.length).toBeGreaterThanOrEqual(hiddenPages.length) + expect(hiddenPageHrefs.length).toBeGreaterThan(0) }) test('are not listed at /early-access in production', async () => { @@ -383,10 +386,8 @@ describe('server', () => { }) test('have noindex meta tags', async () => { - if (hiddenPageHrefs.length > 0) { - const $ = await getDOM(hiddenPageHrefs[0]) - expect($('meta[content="noindex"]').length).toBe(1) - } + const $ = await getDOM(hiddenPageHrefs[0]) + expect($('meta[content="noindex"]').length).toBe(1) }) test('public articles do not have noindex meta tags', async () => {