Changeset 54036
- Timestamp:
- 08/31/2022 10:11:30 AM (2 years ago)
- Location:
- trunk/tests/phpunit
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/data/languages/themes/block-theme-pl_PL.po
r52049 r54036 3 3 "Project-Id-Version: \n" 4 4 "POT-Creation-Date: 2015-12-31 16:31+0100\n" 5 "PO-Revision-Date: 2021-03-15 13:10+0100\n" 5 "PO-Revision-Date: 2022-08-31 11:08+0200\n" 6 "Last-Translator: \n" 7 "Language-Team: \n" 6 8 "Language: pl_PL\n" 7 9 "MIME-Version: 1.0\n" 8 10 "Content-Type: text/plain; charset=UTF-8\n" 9 11 "Content-Transfer-Encoding: 8bit\n" 10 "X-Generator: Poedit 2.4.2\n" 12 "Plural-Forms: nplurals=2; plural=(n != 1);\n" 13 "X-Generator: Poedit 3.1.1\n" 11 14 "X-Poedit-Basepath: .\n" 12 "Plural-Forms: nplurals=2; plural=(n != 1);\n"13 15 "X-Poedit-KeywordsList: __;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;" 14 16 "_nx_noop:1,2,3c;esc_attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;" 15 17 "esc_html_x:1,2c\n" 16 18 "X-Textdomain-Support: yes\n" 17 "Last-Translator: \n"18 "Language-Team: \n"19 19 "X-Poedit-SearchPath-0: .\n" 20 21 msgctxt "Style variation name" 22 msgid "Block theme" 23 msgstr "Motyw blokowy" 24 25 msgctxt "Style variation name" 26 msgid "Block theme variation" 27 msgstr "Wariant motywu blokowego" 20 28 21 29 msgctxt "Custom template name" -
trunk/tests/phpunit/data/themedir1/block-theme/styles/variation.json
r53072 r54036 1 1 { 2 "version": 2, 3 "settings": { 4 "color": { 5 "palette": [ 6 { 7 "slug": "foreground", 8 "color": "#3F67C6", 9 "name": "Foreground" 10 } 11 ] 12 } 13 }, 14 "styles": { 15 "blocks": { 16 "core/post-title": { 17 "typography": { 18 "fontWeight": "700" 19 } 20 } 21 } 22 } 2 "version": 2, 3 "title": "Block theme variation", 4 "settings": { 5 "color": { 6 "palette": [ 7 { 8 "slug": "foreground", 9 "color": "#3F67C6", 10 "name": "Foreground" 11 } 12 ] 13 } 14 }, 15 "styles": { 16 "blocks": { 17 "core/post-title": { 18 "typography": { 19 "fontWeight": "700" 20 } 21 } 22 } 23 } 23 24 } -
trunk/tests/phpunit/data/themedir1/block-theme/theme.json
r52049 r54036 1 1 { 2 2 "version": 1, 3 "title": "Block theme", 3 4 "settings": { 4 5 "color": { … … 37 38 }, 38 39 "spacing": { 39 "units": [ 40 "rem" 41 ], 40 "units": ["rem"], 42 41 "customPadding": true 43 42 }, -
trunk/tests/phpunit/tests/rest-api/rest-global-styles-controller.php
r53921 r54036 472 472 array( 473 473 'version' => 2, 474 'title' => 'Block theme variation', 474 475 'settings' => array( 475 476 'color' => array( … … 494 495 ), 495 496 ), 496 'title' => 'variation',497 497 ), 498 498 ); -
trunk/tests/phpunit/tests/theme/wpThemeJsonResolver.php
r53916 r54036 83 83 84 84 switch_theme( 'block-theme' ); 85 $actual = WP_Theme_JSON_Resolver::get_theme_data(); 85 $theme_data = WP_Theme_JSON_Resolver::get_theme_data(); 86 $style_variations = WP_Theme_JSON_Resolver::get_style_variations(); 86 87 87 88 unload_textdomain( 'block-theme' ); 88 89 remove_filter( 'locale', array( $this, 'filter_set_locale_to_polish' ) ); 89 90 90 $this->assertSame( wp_get_theme()->get( 'TextDomain' ), 'block-theme' ); 91 $this->assertSame( 91 $this->assertSame( 'block-theme', wp_get_theme()->get( 'TextDomain' ) ); 92 $this->assertSame( 'Motyw blokowy', $theme_data->get_data()['title'] ); 93 $this->assertSameSets( 92 94 array( 93 95 'color' => array( … … 151 153 ), 152 154 ), 153 $actual->get_settings() 154 ); 155 $this->assertSame( 156 $actual->get_custom_templates(), 155 $theme_data->get_settings() 156 ); 157 $this->assertSameSets( 157 158 array( 158 159 'page-home' => array( … … 160 161 'postTypes' => array( 'page' ), 161 162 ), 162 ) 163 );164 $this->assertSame(165 $actual->get_template_parts(),163 ), 164 $theme_data->get_custom_templates() 165 ); 166 $this->assertSameSets( 166 167 array( 167 168 'small-header' => array( … … 169 170 'area' => 'header', 170 171 ), 171 ) 172 ), 173 $theme_data->get_template_parts() 174 ); 175 $this->assertSame( 176 'Wariant motywu blokowego', 177 $style_variations[0]['title'] 172 178 ); 173 179 }
Note: See TracChangeset
for help on using the changeset viewer.