Skip to content

Commit 335b15e

Browse files
committed
update request url for test
1 parent ddd703e commit 335b15e

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

e2e/test-utils/stackable.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@ export class StackableFixture {
1717
}
1818

1919
const finishedCallback = async ( request: Request ) => {
20-
console.log( 'url', request.url() )
21-
if ( request.url().includes( 'stackable/v3/settings' ) && request.method() === 'GET' ) {
20+
if ( ( request.url().includes( 'stackable/v3/settings' ) || request.url().includes( 'stackable%2Fv3%2Fsettings' ) ) && request.method() === 'GET' ) {
2221
try {
2322
let settings = null
2423
await test.step( 'Wait for Stackable settings to load', async () => {
@@ -39,7 +38,7 @@ export class StackableFixture {
3938
}
4039
}
4140
const failedCallback = async ( request: Request ) => {
42-
if ( request.url().includes( 'stackable/v3/settings' ) && request.method() === 'GET' ) {
41+
if ( ( request.url().includes( 'stackable/v3/settings' ) || request.url().includes( 'stackable%2Fv3%2Fsettings' ) ) && request.method() === 'GET' ) {
4342
cleanup()
4443
throw Error( 'Failed to get Stackable settings' )
4544
}

e2e/tests/admin.spec.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,7 @@ test( 'Stackable settings should be saved', async ( {
4242

4343
// There should be no PHP errors
4444
const pageError = await admin.getPageError()
45-
46-
console.log( 'getting page error' )
4745
expect( pageError ).toBeNull()
48-
console.log( 'no page error' )
4946

5047
// Retrieves the value of the first option, toggles it and check if the value changed
5148
const option = page.locator( '.ugb-admin-toggle-setting' ).first().getByRole( 'switch' )

0 commit comments

Comments
 (0)