Repository navigation
Supported comma-separated recipients addresses - #3139
Conversation
Bundle Size Diff
|
|
Plugin build for 8b3e291 is ready 🛎️!
|
E2E TestsPlaywright Test Status: See serial and parallel matrix jobs Performance ResultsserverResponse: {"q25":471.86,"q50":492.3,"q75":521.08,"cnt":10}, firstPaint: {"q25":1541.67,"q50":1645.7,"q75":1866.84,"cnt":10}, domContentLoaded: {"q25":4410.64,"q50":4418.75,"q75":4444.85,"cnt":10}, loaded: {"q25":4414.17,"q50":4422.23,"q75":4448.58,"cnt":10}, firstContentfulPaint: {"q25":2871.96,"q50":3277.54,"q75":3322.18,"cnt":10}, firstBlock: {"q25":20224.11,"q50":20242.17,"q75":20348.11,"cnt":10}, type: {"q25":30.07,"q50":32.81,"q75":35.59,"cnt":10}, typeWithoutInspector: {"q25":29.76,"q50":32.56,"q75":35.99,"cnt":10}, typeWithTopToolbar: {"q25":41.34,"q50":52.19,"q75":62.08,"cnt":10}, typeContainer: {"q25":18.97,"q50":19.56,"q75":19.93,"cnt":10}, focus: {"q25":160.66,"q50":167.67,"q75":174.26,"cnt":10}, inserterOpen: {"q25":49.49,"q50":51.32,"q75":58.49,"cnt":10}, inserterSearch: {"q25":34.09,"q50":35.29,"q75":36.97,"cnt":10}, inserterHover: {"q25":5.11,"q50":5.52,"q75":5.84,"cnt":20}, loadPatterns: {"q25":2163.51,"q50":2188.88,"q75":2202.23,"cnt":10}, listViewOpen: {"q25":286.38,"q50":290.72,"q75":307.28,"cnt":10} |
There was a problem hiding this comment.
🟡 Changes requested
The comma-separated recipient support works, but add a test for the new test-email fallback when every address is invalid.
Validation details
- Files reviewed: 5/5 changed files.
- PHPUnit 9.6.5 on PHP 8.3.35 passed the new tests at HEAD
cd /repo; set -o pipefail; timeout 280 vendor/bin/phpunit --do-not-cache-result --filter 'Test_Abilities::' 2>&1 | tee /…(run R3, exit 0)cd /repo; set -o pipefail; timeout 280 vendor/bin/phpunit --do-not-cache-result --filter 'Test_Form_Server::test_(fronte…(run R4, exit 0). - On the base tree, 5 of the 7 new cases failed on the changed assertion. That run has no run record.
- The editor value reaches the stored option with commas intact.
sanitize_text_fieldkeeps them. - Every To and From address passes
sanitize_emailandis_email. The route permissions did not change.
Untested areas
- The Email To field was not checked in a browser. The sandbox has no built assets.
- Real delivery to several recipients was not run. The tests mock
wp_mail.
🤖 Automated review · run code-review-agent_6ae08e5d7bcae6.75671950.
🤖 Review agent — review posted ✅ on d8999e4f · changes requested · 1 finding · 10 min
Run code-review-agent_6ae08e5d7bcae6.75671950 · trail
There was a problem hiding this comment.
🟢 Approved
The PR passes. The new test covers the all-invalid test-email fallback that the earlier review asked for.
Validation details
- Files reviewed: 5/5 changed files. Only
tests/test-form-server.phpchanged since the earlier review. - PHPUnit 9.6 on PHP 8.3.35 passed the new test at HEAD:
cd /workspace; set -o pipefail; sandbox-wp-tests.sh 2>&1 | tail -5; echo "exit ${PIPESTATUS[0]}"; cd /repo && set -o pip…printedOK (1 test, 3 assertions)(run R1). - The new test is the only one that sends a non-empty
towith only invalid entries. - Earlier results from run code-review-agent_6ae08e5d7bcae6.75671950 at
d8999e4still apply, not rerun. The non-test code did not change since then.
Untested areas
- The Email To field was not checked in a browser. The sandbox has no built assets.
- Real delivery to several recipients was not run. The tests mock
wp_mail.
🤖 Automated review · run code-review-agent_6ae091a12c3169.46331047.
🤖 Review agent — review posted ✅ on 8b3e2917 · approved · 0 findings · 4 min
Run code-review-agent_6ae091a12c3169.46331047 · trail
Closes #3137
Summary
Updated the Form notification Email To field to support comma-separated email addresses, sanitizing each entry, excluding invalid addresses, and sending notifications to all valid recipients with a fallback to the site admin if none remain. Updated test emails to use the same recipient list, with the first address as the sender, and modified the
otter/update-formAbilities API to accept comma-separatedemail_tovalues while rejecting lists containing invalid addresses.Checklist before the final review