From 2fe553c3fc523cbca4cea58804abd39aea4f580e Mon Sep 17 00:00:00 2001 From: Daniel Richards Date: Wed, 10 Apr 2019 12:00:56 +0800 Subject: [PATCH] Add publish step to preview with custom fields test --- packages/e2e-tests/specs/preview.test.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/e2e-tests/specs/preview.test.js b/packages/e2e-tests/specs/preview.test.js index da77d0690aebfb..3379801446cbdd 100644 --- a/packages/e2e-tests/specs/preview.test.js +++ b/packages/e2e-tests/specs/preview.test.js @@ -218,6 +218,11 @@ describe( 'Preview with Custom Fields enabled', async () => { await editorPage.keyboard.press( 'Tab' ); await editorPage.keyboard.type( 'content 1' ); + // Publish the post and then close the publish panel. + await publishPost(); + await page.waitForSelector( '.editor-post-publish-panel' ); + await page.click( '.editor-post-publish-panel__header button' ); + // Open the preview page. const previewPage = await openPreviewPage( editorPage );