PluginProbe
Extendify / 3.1.0
Extendify v3.1.0
3.2.1 3.2.0 3.1.6 3.1.5 3.1.4 3.1.3 3.1.2 3.1.1 3.1.0 3.0.6 3.0.5 3.0.4 trunk 0.1.0 0.10.0 0.10.1 0.10.2 0.11.0 0.11.1 0.2.0 0.3.0 0.3.1 0.4.0 0.5.0 0.6.0 All 127 releases
extendify / tests / playwright / setup.php

setup.php in Extendify 3.1.0, at tests/playwright/setup.php

27 lines 950 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 require '/wordpress/wp-load.php';
3
4 $userId = 1;
5
6 // Mirrors the user-meta block in cypress/support/helpers.js cy.resetAll() so
7 // specs don't have to dismiss welcome guides / pattern modals on first paint.
8 $userSettings = [
9 'core/edit-post' => [
10 'welcomeGuide' => false,
11 'core/edit-post/pattern-modal' => false,
12 'pattern-modal' => false,
13 'edit-post/pattern-modal' => false,
14 'patternModal' => false,
15 ],
16 'core/edit-site' => ['welcomeGuide' => false],
17 'core' => ['enableChoosePatternModal' => false],
18 '_modified' => gmdate('c'),
19 ];
20 update_user_meta($userId, 'wp_persisted_preferences', $userSettings);
21
22 // Theme-agnostic "blueprint applied" marker for global-setup.ts. setup.php is
23 // the last blueprint step, so this lands after every other seed. Exposed via
24 // the public /?rest_route=/ JSON root (which echoes blogdescription) so the
25 // poller doesn't need auth.
26 update_option('blogdescription', 'extendify-pw-blueprint-ready');
27