From a04fa6650d8461381a249fd74699b5efa285ea74 Mon Sep 17 00:00:00 2001 From: kielllll Date: Tue, 19 Nov 2024 00:54:34 +0800 Subject: [PATCH] fix: page url redirect action --- tests/e2e/advanced-checks/pdf-restriction.test.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/e2e/advanced-checks/pdf-restriction.test.js b/tests/e2e/advanced-checks/pdf-restriction.test.js index f8ab96197..28576c247 100644 --- a/tests/e2e/advanced-checks/pdf-restriction.test.js +++ b/tests/e2e/advanced-checks/pdf-restriction.test.js @@ -94,7 +94,10 @@ test( 'reset/clean previous tests saved data and ensure PDF can be viewed by def await advancedCheck.toggleRestrictOwnerCheckbox( 'gf_edit_forms&view=settings&subview=PDF&id=4' ); - await t.useRole( Role.anonymous() ).navigateTo( `${ baseURL }/test-page/` ); + const postParam = await getQueryParam( 'post' ); + await t + .useRole( Role.anonymous() ) + .navigateTo( `${ baseURL }/?page_id=${ postParam }` ); await advancedCheck.submitNewPdfEntry(); await t.useRole( admin );