Commit 03c4709
committed
fix(e2e): load text domain at init priority 1 and disable WP_DEBUG_DISPLAY
In WP 6.7+, register_block_type() translates block.json strings via __()
at init priority 10, before load_plugin_textdomain() ran (also priority
10, but registered later). This triggered the JIT textdomain notice which
output text before headers, breaking cookie-based login in E2E tests.
Moving load_plugin_textdomain to priority 1 ensures the domain is loaded
before any __() calls during block registration.
WP_DEBUG_DISPLAY: false prevents any future PHP notices from reaching the
browser output stream, keeping wp-login.php headers intact in wp-env.
Made-with: Cursor1 parent f42dcc4 commit 03c4709
2 files changed
Lines changed: 11 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
10 | 15 | | |
11 | 16 | | |
12 | 17 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
90 | 90 | | |
91 | 91 | | |
92 | 92 | | |
93 | | - | |
| 93 | + | |
| 94 | + | |
94 | 95 | | |
95 | 96 | | |
96 | 97 | | |
97 | 98 | | |
98 | | - | |
| 99 | + | |
| 100 | + | |
99 | 101 | | |
| 102 | + | |
100 | 103 | | |
101 | 104 | | |
102 | 105 | | |
| |||
0 commit comments