Skip to content

Fix CakePHP 5.3 deprecation warnings in tests#372

Merged
ADmad merged 3 commits intoFriendsOfCake:masterfrom
dereuromark:fix/cakephp-53-deprecations
Jan 29, 2026
Merged

Fix CakePHP 5.3 deprecation warnings in tests#372
ADmad merged 3 commits intoFriendsOfCake:masterfrom
dereuromark:fix/cakephp-53-deprecations

Conversation

@dereuromark
Copy link
Copy Markdown
Member

Summary

  • Replace _execute() with process() in test form anonymous class (deprecated since CakePHP 5.3.0)
  • Replace $table->searchManager() with $table->getBehavior('Search')->searchManager() in test table classes and behavior tests (calling behavior methods via table proxy deprecated since CakePHP 5.3.0)
  • Replace $table->isSearch() with $table->getBehavior('Search')->isSearch() in behavior tests

These 3 deprecation warnings cause the MySQL 8.2 CI job to fail with --display-deprecations.

- Replace _execute() with process() in test form class
- Use getBehavior('Search')->searchManager() instead of table proxy
- Use getBehavior('Search')->isSearch() instead of table proxy
@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.35%. Comparing base (7132608) to head (ddc132b).
⚠️ Report is 10 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##             master     #372   +/-   ##
=========================================
  Coverage     91.35%   91.35%           
  Complexity      240      240           
=========================================
  Files            19       19           
  Lines           694      694           
=========================================
  Hits            634      634           
  Misses           60       60           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@dereuromark dereuromark requested a review from ADmad January 28, 2026 18:33
@ADmad ADmad merged commit a0cb9ee into FriendsOfCake:master Jan 29, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants