- Timestamp:
- 11/18/2025 10:10:49 AM (5 months ago)
- Location:
- branches/6.9
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
tests/phpunit/tests/dependencies/scripts.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/6.9
-
branches/6.9/tests/phpunit/tests/dependencies/scripts.php
r61176 r61260 4076 4076 $this->assertEqualHTML( $expected, $print_scripts ); 4077 4077 } 4078 4079 /** 4080 * Ensure that `::print_translations()` does not include the sourceURL comment when `$display` is false. 4081 * 4082 * @ticket 63887 4083 * @covers ::print_translations 4084 */ 4085 public function test_print_translations_no_display_no_sourceurl() { 4086 global $wp_scripts; 4087 $this->add_html5_script_theme_support(); 4088 4089 wp_register_script( 'wp-i18n', '/wp-includes/js/dist/wp-i18n.js', array(), null ); 4090 wp_enqueue_script( 'test-example', '/wp-includes/js/script.js', array(), null ); 4091 wp_set_script_translations( 'test-example', 'default', DIR_TESTDATA . '/languages' ); 4092 4093 $translations_script_data = $wp_scripts->print_translations( 'test-example', false ); 4094 $this->assertStringNotContainsStringIgnoringCase( 'sourceURL=', $translations_script_data ); 4095 } 4078 4096 }
Note: See TracChangeset
for help on using the changeset viewer.