Changeset 54447
- Timestamp:
- 10/10/2022 05:57:52 PM (2 years ago)
- Location:
- trunk
- Files:
-
- 1 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/load.php
r54332 r54447 1151 1151 * @return bool True if inside WordPress login screen, false otherwise. 1152 1152 */ 1153 function is_login _screen() {1153 function is_login() { 1154 1154 return false !== stripos( wp_login_url(), $_SERVER['SCRIPT_NAME'] ); 1155 1155 } -
trunk/tests/phpunit/tests/load/isLogin.php
r54446 r54447 2 2 3 3 /** 4 * Tests for is_login _screen().4 * Tests for is_login(). 5 5 * 6 6 * @group load.php 7 * @covers ::is_login _screen7 * @covers ::is_login 8 8 */ 9 class Tests_Load_IsLogin Screenextends WP_UnitTestCase {9 class Tests_Load_IsLogin extends WP_UnitTestCase { 10 10 11 11 /** 12 12 * @ticket 19898 13 13 */ 14 public function test_is_login _screen() {15 $this->assertFalse( is_login _screen() );14 public function test_is_login() { 15 $this->assertFalse( is_login() ); 16 16 17 17 $_SERVER['SCRIPT_NAME'] = '/wp-login.php'; 18 18 19 $this->assertTrue( is_login _screen() );19 $this->assertTrue( is_login() ); 20 20 } 21 21 }
Note: See TracChangeset
for help on using the changeset viewer.