Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
560318a
Add Playwright e2e hello-world test with CI job
PatelUtkarsh Apr 24, 2026
ede1be9
Add Playwright e2e tests for Cloudinary plugin activation and admin menu
PatelUtkarsh May 1, 2026
558797b
Trigger CI on pull_request events
PatelUtkarsh May 1, 2026
232e369
Merge branch 'master' into develop
gabriel-detassigny May 5, 2026
b56db46
Merge pull request #1164 from PatelUtkarsh/chore/e2e-hello-world
gabrielcld2 May 7, 2026
b1843de
Add Playwright e2e test for Cloudinary setup wizard (WPP-1201)
PatelUtkarsh May 7, 2026
22df49b
Pass CLOUDINARY_E2E_URL secret to e2e workflow
PatelUtkarsh May 7, 2026
450afc6
refactor(tests): remove internal ticket reference from wizard e2e test
PatelUtkarsh May 8, 2026
b36ae48
Add collapsible behavior to term edit page
gabriel-detassigny May 18, 2026
7ab989a
Build assets
gabriel-detassigny May 18, 2026
f2d371f
Improve deactivation modal styling
gabriel-detassigny May 19, 2026
82ffa44
Fix fatal in is_oversize_media when usage data is a string
PatelUtkarsh May 22, 2026
c4e24b4
Guard remaining consumers of usage / last_usage against string values
PatelUtkarsh May 23, 2026
44d6133
Harden additional stored-state consumers against non-array values
PatelUtkarsh May 23, 2026
22480b5
Merge pull request #1171 from PatelUtkarsh/feature/wizard-e2e
gabrielcld2 May 25, 2026
b56ae6a
Re-establish cursor: pointer to toggle element
gabriel-detassigny May 25, 2026
4b45d88
Merge pull request #1174 from cloudinary/feature/taxonomy-fields-drop…
gabrielcld2 May 25, 2026
a3f0e53
Remove extra line
gabrielcld2 May 28, 2026
030723e
Merge branch 'develop' into feature/deactivation-form-styling
gabriel-detassigny May 28, 2026
ae9bcc8
Merge branch 'feature/deactivation-form-styling' of cld.github.com:cl…
gabriel-detassigny May 28, 2026
03e35f2
Merge pull request #1175 from cloudinary/feature/deactivation-form-st…
gabrielcld2 May 28, 2026
0887ad5
Guard Elementor CSS replacement when plugin is not connected
PatelUtkarsh Jun 1, 2026
29d97a6
test(e2e): add fixture image for Cloudinary delivery spec
PatelUtkarsh May 21, 2026
bb71d8d
test(e2e): add connection helper for image delivery spec
PatelUtkarsh May 21, 2026
ac97f14
test(e2e): scaffold Cloudinary image delivery spec
PatelUtkarsh May 21, 2026
31083f8
test(e2e): set up REST-driven post + media lifecycle for image delive…
PatelUtkarsh May 21, 2026
5f68375
test(e2e): assert featured + inline images are served via Cloudinary
PatelUtkarsh May 21, 2026
691d8c4
test(e2e): trigger sync + handle lazy-load to assert Cloudinary delivery
PatelUtkarsh Jun 3, 2026
7214bd3
test(e2e): assert via data-public-id + larger fixture for CI stability
PatelUtkarsh Jun 3, 2026
bfb75fd
test(e2e): add fixture video for Cloudinary delivery spec
PatelUtkarsh Jun 3, 2026
574a99c
test(e2e): scaffold Cloudinary video delivery spec
PatelUtkarsh Jun 3, 2026
ba95d9c
test(e2e): set up REST-driven video lifecycle for delivery spec
PatelUtkarsh Jun 3, 2026
7d24ba6
test(e2e): assert core/video block is served via Cloudinary
PatelUtkarsh Jun 3, 2026
b167cf0
test(e2e): wrap wp-player video test in nested describe
PatelUtkarsh Jun 3, 2026
bff7bc9
test(e2e): scaffold Cloudinary player describe with setting toggle
PatelUtkarsh Jun 3, 2026
6274022
test(e2e): assert Cloudinary player iframe carries our cloud + public_id
PatelUtkarsh Jun 3, 2026
00300d3
test(e2e): use option patch insert so cld-player toggle works on fres…
PatelUtkarsh Jun 4, 2026
43b96b3
test(e2e): set video_player via merge-based wp eval to handle fresh w…
PatelUtkarsh Jun 4, 2026
f519537
Merge pull request #1177 from cloudinary/feature/e2e-cloudinary-images
gabrielcld2 Jun 8, 2026
136b141
test(e2e): read video/source src in one evaluate
PatelUtkarsh Jun 11, 2026
2697329
test(e2e): bound setVideoPlayer execSync with a timeout
PatelUtkarsh Jun 11, 2026
7f63ec7
Merge pull request #1178 from cloudinary/feature/e2e-cloudinary-videos
gabrielcld2 Jun 17, 2026
832406d
Fix PHP 8.4 null deprecation warnings in class-delivery.php
PatelUtkarsh Jun 18, 2026
32323cd
Merge remote-tracking branch 'origin/develop' into pr1176-update
PatelUtkarsh Jun 18, 2026
6babc5a
Merge pull request #1179 from cloudinary/bugfix/php84-delivery-null-w…
gabrielcld2 Jun 18, 2026
6d68969
Merge pull request #1176 from PatelUtkarsh/bugfix/is-oversize-media-s…
gabrielcld2 Jun 18, 2026
70adce8
Add filter to disable Elementor background images integration
gabriel-detassigny Jun 22, 2026
2932026
Fix duplicate Cloudinary assets created when upload succeeds but DB w…
gabriel-detassigny Jun 22, 2026
2a51622
Merge branch 'develop' into bugfix/elementor-bg-images
gabriel-detassigny Jun 22, 2026
3ab33cf
Merge pull request #1181 from cloudinary/bugfix/elementor-bg-images
gabrielcld2 Jun 22, 2026
14e661b
Merge pull request #1182 from cloudinary/fix/duplicate-cloudinary-ass…
gabrielcld2 Jun 22, 2026
79621a8
Update i18n files
gabriel-detassigny Jun 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Copy to `.env` and fill in real values. `.env` is gitignored.
#
# Used by Playwright (tests/e2e/playwright.config.js) at e2e startup.

# Cloudinary connection string consumed by the wizard e2e spec
# (tests/e2e/wizard-setup.spec.js). Use a dedicated test account —
# never production credentials. See README "End-to-end testing" for
# why this is named CLOUDINARY_E2E_URL rather than CLOUDINARY_URL.
CLOUDINARY_E2E_URL=cloudinary://API_KEY:API_SECRET@CLOUD_NAME
43 changes: 43 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ name: CI

on:
push:
pull_request:

jobs:
build:
Expand Down Expand Up @@ -41,3 +42,45 @@ jobs:

- name: Run build
run: npm run build

e2e:
name: E2E (Playwright)
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install dependencies
run: npm ci

- name: Install Playwright browsers
run: npx playwright install --with-deps chromium

- name: Build assets
run: npm run build

- name: Start wp-env
run: npm run env:start

- name: Run E2E tests
env:
CLOUDINARY_E2E_URL: ${{ secrets.CLOUDINARY_E2E_URL }}
run: npm run test:e2e

- name: Stop wp-env
if: always()
run: npm run env:stop

- name: Upload Playwright artifacts
if: failure()
uses: actions/upload-artifact@v4
with:
name: playwright-artifacts
path: artifacts/
retention-days: 7
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ js/*.map
tests/data/
tests/includes/
coverage/html/
/artifacts/
/playwright-report/
/test-results/

# ENV files
.env
Expand Down
53 changes: 53 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,59 @@ Files included in the release package are defined in the `gruntfile.js` under th

3. Run `npm run deploy-assets` to deploy just the WP.org plugin assets such as screenshots, icons and banners.

## End-to-end testing

E2E tests run against a wp-env site using Playwright.

### One-time setup

```bash
npm install
npx playwright install --with-deps chromium
npm run env:start
```

### Running the tests

```bash
npm run test:e2e
```

### Wizard test credentials

`tests/e2e/wizard-setup.spec.js` exercises the live Cloudinary connection flow, so it needs a real connection string. Provide one of two ways:

**Option 1 — `.env` file (recommended for sustained local development).** Copy `.env.example` to `.env` and fill in the value. `.env` is gitignored. Playwright loads it automatically at startup.

```bash
cp .env.example .env
# edit .env, set CLOUDINARY_E2E_URL=cloudinary://...
npm run test:e2e
```

**Option 2 — shell export (good for one-off runs and CI).**

```bash
export CLOUDINARY_E2E_URL='cloudinary://API_KEY:API_SECRET@CLOUD_NAME'
npm run test:e2e
```

A real shell env var takes precedence over the `.env` file.

The variable is intentionally named `CLOUDINARY_E2E_URL` (not `CLOUDINARY_URL`) so it cannot be confused with the Cloudinary SDK convention or with anything you might define in `.wp-env.override.json` for local dev. Use a dedicated test Cloudinary account — never production credentials.

> **Note:** Do **not** set `CLOUDINARY_URL` or `CLOUDINARY_CONNECTION_STRING` as PHP constants via `.wp-env.override.json` while running this spec. The plugin treats a constant-defined connection string as already-configured and hides the wizard's connection input, which makes the test impossible.

CI will provide `CLOUDINARY_E2E_URL` via a GitHub Actions secret (wired separately under WPP-1195's CI subtask).

### Debugging a failing e2e test

```bash
npm run test:e2e:debug -- wizard-setup
```

This opens Playwright's UI runner where you can step through actions, inspect the DOM, and view the network panel.

## License

Released under the GPL license.
2 changes: 1 addition & 1 deletion css/cloudinary.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/cloudinary.js

Large diffs are not rendered by default.

79 changes: 43 additions & 36 deletions languages/cloudinary.pot
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Cloudinary STABLETAG\n"
"Report-Msgid-Bugs-To: https://github.com/cloudinary/cloudinary_wordpress\n"
"POT-Creation-Date: 2026-04-27 07:42:18+00:00\n"
"POT-Creation-Date: 2026-06-22 09:16:52+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
Expand Down Expand Up @@ -253,11 +253,11 @@ msgstr ""
msgid "CNAME is not a valid domain name."
msgstr ""

#: php/class-connect.php:808
#: php/class-connect.php:819
msgid "upgrade your account"
msgstr ""

#: php/class-connect.php:823
#: php/class-connect.php:834
#. translators: %1$s quota size, %2$s amount in percent, %3$s link URL, %4$s
#. link anchor text.
msgid ""
Expand All @@ -269,11 +269,11 @@ msgid ""
"full functionality."
msgstr ""

#: php/class-connect.php:1018
#: php/class-connect.php:1029
msgid "Cloudinary was able to connect to the WordPress REST API."
msgstr ""

#: php/class-connect.php:1035 php/class-connect.php:1045
#: php/class-connect.php:1046 php/class-connect.php:1056
#. translators: 1: The WordPress error message. 2: The WordPress error code.
msgid "The Cloudinary REST API endpoints are not available. Error: %1$s (%2$s)"
msgstr ""
Expand Down Expand Up @@ -506,64 +506,64 @@ msgstr ""
msgid "Unsynced"
msgstr ""

#: php/class-media.php:459
#: php/class-media.php:470
#. translators: variable is file size.
msgid ""
"File size exceeds the maximum of %s. This media asset will be served from "
"WordPress."
msgstr ""

#: php/class-media.php:2070
#: php/class-media.php:2081
msgid "Import"
msgstr ""

#. Plugin Name of the plugin/theme
msgid "Cloudinary"
msgstr ""

#: php/class-media.php:2425
#: php/class-media.php:2436
msgid "The delivery for this asset is disabled."
msgstr ""

#: php/class-media.php:2429
#: php/class-media.php:2440
msgid "Not syncable. This is an external media."
msgstr ""

#: php/class-media.php:2433
#: php/class-media.php:2444
msgid "This media is Fetch type."
msgstr ""

#: php/class-media.php:2437
#: php/class-media.php:2448
msgid "This media is Sprite type."
msgstr ""

#: php/class-media.php:2447
#: php/class-media.php:2458
msgid "Not Synced"
msgstr ""

#: php/class-media.php:2452
#: php/class-media.php:2463
msgid "Synced"
msgstr ""

#: php/class-media.php:3111
#: php/class-media.php:3122
msgid "No Cloudinary filters"
msgstr ""

#: php/class-media.php:3211
#: php/class-media.php:3222
msgid "Media Settings"
msgstr ""

#: php/class-media.php:3214
#: php/class-media.php:3225
msgid "Media Display"
msgstr ""

#: php/class-media.php:3218 php/ui/component/class-plan-details.php:119
#: php/class-media.php:3229 php/ui/component/class-plan-details.php:129
#: php/ui/component/class-plan-status.php:128
#: ui-definitions/settings-pages.php:568 ui-definitions/settings-sidebar.php:44
#: ui-definitions/settings-pages.php:568 ui-definitions/settings-sidebar.php:47
msgid "Transformations"
msgstr ""

#: php/class-media.php:3219
#: php/class-media.php:3230
msgid ""
"Cloudinary allows you to easily transform your images on-the-fly to any "
"required format, style and dimension, and also optimizes images for minimal "
Expand All @@ -572,7 +572,7 @@ msgid ""
"transformation and delivery URLs."
msgstr ""

#: php/class-media.php:3224 ui-definitions/settings-image.php:175
#: php/class-media.php:3235 ui-definitions/settings-image.php:175
#: ui-definitions/settings-pages.php:594 ui-definitions/settings-video.php:260
msgid "See examples"
msgstr ""
Expand Down Expand Up @@ -736,9 +736,9 @@ msgid ""
"to. Leave blank to use the root of your Cloudinary library."
msgstr ""

#: php/class-sync.php:1286 php/ui/component/class-plan-details.php:118
#: php/class-sync.php:1286 php/ui/component/class-plan-details.php:128
#: php/ui/component/class-plan-status.php:94
#: ui-definitions/settings-sidebar.php:38
#: ui-definitions/settings-sidebar.php:41
msgid "Storage"
msgstr ""

Expand Down Expand Up @@ -1130,7 +1130,7 @@ msgstr ""
msgid "Optimizing assets."
msgstr ""

#: php/sync/class-sync-queue.php:409 php/ui/component/class-plan-details.php:83
#: php/sync/class-sync-queue.php:409 php/ui/component/class-plan-details.php:93
msgid "Optimized assets"
msgstr ""

Expand Down Expand Up @@ -1186,11 +1186,11 @@ msgstr ""
msgid "Starting thread %s."
msgstr ""

#: php/sync/class-sync-queue.php:907
#: php/sync/class-sync-queue.php:909
msgid "Resuming Maybe"
msgstr ""

#: php/sync/class-sync-queue.php:916
#: php/sync/class-sync-queue.php:918
#. translators: variable is thread name.
msgid "Thread %s Stopped."
msgstr ""
Expand Down Expand Up @@ -1291,17 +1291,24 @@ msgstr ""
msgid "60 monthly credits"
msgstr ""

#: php/templates/taxonomy-term-transformation-fields.php:28
#: php/templates/taxonomy-term-transformation-fields.php:25
#. translators: The taxonomy label and the context.
msgid "Cloudinary %1$s %2$s Transformations"
msgstr ""

#: php/templates/taxonomy-term-transformation-fields.php:30
#: php/templates/taxonomy-transformation-fields.php:46
#. translators: The transformation context (e.g. Image, Video).
#. translators: The taxonomy singular label (e.g. Category, Tag).
msgid "Toggle %s transformations"
msgstr ""

#: php/templates/taxonomy-transformation-fields.php:41
#. translators: The taxonomy label.
msgid "Cloudinary %s transformations"
msgstr ""

#: php/templates/taxonomy-transformation-fields.php:51
#: php/templates/taxonomy-transformation-fields.php:60
#. translators: %1$s is the taxonomy label, %2$s is the image settings link,
#. %4$s is the video settings link. The %3$s is the closing tags for the links.
msgid ""
Expand Down Expand Up @@ -1500,25 +1507,25 @@ msgstr ""
msgid "%s unoptimized"
msgstr ""

#: php/ui/component/class-plan-details.php:74
#: php/ui/component/class-plan-details.php:84
msgid "Plan"
msgstr ""

#: php/ui/component/class-plan-details.php:82
#: php/ui/component/class-plan-details.php:92
msgid "Total Requests"
msgstr ""

#: php/ui/component/class-plan-details.php:103
#: php/ui/component/class-plan-details.php:113
msgid "Plan Units"
msgstr ""

#: php/ui/component/class-plan-details.php:104
#: php/ui/component/class-plan-details.php:114
msgid "Remaining Units"
msgstr ""

#: php/ui/component/class-plan-details.php:120
#: php/ui/component/class-plan-details.php:130
#: php/ui/component/class-plan-status.php:161
#: ui-definitions/settings-sidebar.php:49
#: ui-definitions/settings-sidebar.php:52
msgid "Bandwidth"
msgstr ""

Expand Down Expand Up @@ -2369,15 +2376,15 @@ msgstr ""
msgid "Account status"
msgstr ""

#: ui-definitions/settings-sidebar.php:56
#: ui-definitions/settings-sidebar.php:59
msgid "View my account status"
msgstr ""

#: ui-definitions/settings-sidebar.php:69
#: ui-definitions/settings-sidebar.php:72
msgid "Optimization level"
msgstr ""

#: ui-definitions/settings-sidebar.php:75
#: ui-definitions/settings-sidebar.php:78
#. translators: %s is the percentage optimized.
msgid "%s Optimized"
msgstr ""
Expand Down
Loading
Loading