diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml
index 763fa51a..0d98884c 100644
--- a/.github/workflows/integration-tests.yml
+++ b/.github/workflows/integration-tests.yml
@@ -21,7 +21,7 @@ jobs:
- { wp: 60, php: 74 }
- { wp: 63, php: 80 }
- { wp: 67, php: 82 }
- - { wp: 68, php: 83 }
+ - { wp: 69, php: 83 }
steps:
- name: Checkout code
uses: actions/checkout@v4
diff --git a/config/docker/68-83.Dockerfile b/config/docker/68-83.Dockerfile
deleted file mode 100644
index e47ac4cf..00000000
--- a/config/docker/68-83.Dockerfile
+++ /dev/null
@@ -1 +0,0 @@
-FROM wordpress:6.8-php8.3-apache
\ No newline at end of file
diff --git a/config/docker/69-83.Dockerfile b/config/docker/69-83.Dockerfile
new file mode 100644
index 00000000..8a5f8923
--- /dev/null
+++ b/config/docker/69-83.Dockerfile
@@ -0,0 +1 @@
+FROM wordpress:6.9-php8.3-apache
\ No newline at end of file
diff --git a/config/mysql/additional.cnf b/config/mysql/additional.cnf
deleted file mode 100644
index 91585318..00000000
--- a/config/mysql/additional.cnf
+++ /dev/null
@@ -1,3 +0,0 @@
-[mysqld]
-# Required for WordPress 3.8 and below.
-sql-mode="NO_ENGINE_SUBSTITUTION"
diff --git a/config/wp-version.conf b/config/wp-version.conf
index 59f3270c..df12d545 100644
--- a/config/wp-version.conf
+++ b/config/wp-version.conf
@@ -5,4 +5,4 @@
60_74=wordpress:6.0-php7.4-apache
63_80=wordpress:6.3-php8.0-apache
67_82=wordpress:6.7-php8.2-apache
-68_83=wordpress:6.8-php8.3-apache
\ No newline at end of file
+69_83=wordpress:6.9-php8.3-apache
\ No newline at end of file
diff --git a/test/integration/compression.spec.ts b/test/integration/compression.spec.ts
index e8fbf436..140d7d09 100644
--- a/test/integration/compression.spec.ts
+++ b/test/integration/compression.spec.ts
@@ -151,7 +151,8 @@ test.describe('compression', () => {
await page.goto('/wp-admin/upload.php');
await page.getByRole('button', { name: 'Compress', exact: true }).click();
- await expect(page.getByText('2 sizes compressed')).toBeVisible();
+ // check interval is 5s so wait atleast 6s
+ await expect(page.getByText('2 sizes compressed')).toBeVisible({ timeout: 6000 });
});
test('compress button in edit screen should compress webp images', async () => {
@@ -167,7 +168,8 @@ test.describe('compression', () => {
await page.goto('/wp-admin/upload.php');
await page.getByRole('button', { name: 'Compress', exact: true }).click();
- await expect(page.getByText('3 sizes compressed')).toBeVisible();
+ // check interval is 5s so wait atleast 6s
+ await expect(page.getByText('3 sizes compressed')).toBeVisible({ timeout: 6000 });
});
test('compress button should compress uncompressed sizes', async () => {
diff --git a/test/integration/conversion.spec.ts b/test/integration/conversion.spec.ts
index 7736207a..2b04e547 100644
--- a/test/integration/conversion.spec.ts
+++ b/test/integration/conversion.spec.ts
@@ -49,14 +49,18 @@ test.describe('conversion', () => {
test('will display the optimized image on a page', async () => {
const media = await uploadMedia(page, 'input-example.jpg');
- const postURL = await newPost(page, {
- title: 'test',
- content: `
`,
- }, WPVersion);
-
- await page.goto(postURL);
-
- const picture = await page.locator('picture:has(source[srcset*="input-example.avif"][type="image/avif"])');
+ const postID = await newPost(
+ page,
+ {
+ title: 'test',
+ content: `
`,
+ },
+ WPVersion
+ );
+
+ await page.goto(`/?p=${postID}`);
+
+ const picture = await page.locator('picture:has(source[srcset*="input-example.avif"][type="image/avif"])');
await expect(picture).toBeVisible();
});
});
diff --git a/test/integration/utils.ts b/test/integration/utils.ts
index 0fd4009a..5bcfbc7c 100644
--- a/test/integration/utils.ts
+++ b/test/integration/utils.ts
@@ -9,11 +9,8 @@ export async function uploadMedia(page: Page, file: string): Promise {
await page.getByLabel('Upload').click();
const fileChooser = await fileChooserPromise;
await fileChooser.setFiles(path.join(__dirname, `../fixtures/${file}`));
- await Promise.all([
- page.waitForURL('**/wp-admin/upload.php**', { waitUntil: 'load' }),
- page.locator('#html-upload').click(),
- ]);
-
+ await Promise.all([page.waitForURL('**/wp-admin/upload.php**', { waitUntil: 'load' }), page.locator('#html-upload').click()]);
+
await page.goto('/wp-admin/upload.php?mode=list');
const row = await page.locator('table.wp-list-table tbody > tr').first();
@@ -23,10 +20,7 @@ export async function uploadMedia(page: Page, file: string): Promise {
const rowID = await row.getAttribute('id');
const attachmentID = rowID?.split('-')[1];
- await Promise.all([
- page.waitForURL(new RegExp(`/wp-admin/post\\.php\\?post=${attachmentID}&action=edit$`), { waitUntil: 'load' }),
- page.goto(`/wp-admin/post.php?post=${attachmentID}&action=edit`),
- ]);
+ await Promise.all([page.waitForURL(new RegExp(`/wp-admin/post\\.php\\?post=${attachmentID}&action=edit$`), { waitUntil: 'load' }), page.goto(`/wp-admin/post.php?post=${attachmentID}&action=edit`)]);
return page.locator('input[name="attachment_url"]').inputValue();
}
@@ -260,13 +254,16 @@ export async function newPost(page: Page, options: NewPostOptions, WPVersion: nu
}, content);
await page.getByRole('button', { name: 'Publish', exact: true }).click();
await page.getByLabel('Editor publish').getByRole('button', { name: 'Publish', exact: true }).click();
- await page.getByLabel('Editor publish').getByRole('link', { name: 'View Post' }).click();
} else {
await page.locator('#content-html').click();
await page.locator('#content').fill(content);
await page.locator('#publish').click();
- await page.getByRole('link', { name: 'View Post' }).first().click();
}
-
- return page.url();
+ await page.waitForURL('**/wp-admin/post.php**');
+ const url = new URL(page.url());
+ const postID = url.searchParams.get('post');
+ if (!postID) {
+ throw new Error('unable to get post id from url');
+ }
+ return postID;
}