Changeset 49754 for branches/5.6/tests/phpunit/tests/rest-api/rest-application-passwords-controller.php
- Timestamp:
- 12/04/2020 09:46:42 PM (4 years ago)
- Location:
- branches/5.6
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/5.6
-
branches/5.6/tests/phpunit/tests/rest-api/rest-application-passwords-controller.php
r49617 r49754 406 406 407 407 /** 408 * @ticket 51939 409 */ 410 public function test_create_item_records_app_passwords_in_use() { 411 wp_set_current_user( self::$admin ); 412 413 $this->assertFalse( WP_Application_Passwords::is_in_use() ); 414 415 $request = new WP_REST_Request( 'POST', '/wp/v2/users/me/application-passwords' ); 416 $request->set_body_params( array( 'name' => 'App' ) ); 417 $response = rest_do_request( $request ); 418 419 $this->assertSame( 201, $response->get_status() ); 420 $this->assertTrue( WP_Application_Passwords::is_in_use() ); 421 } 422 423 /** 408 424 * @ticket 42790 409 425 */
Note: See TracChangeset
for help on using the changeset viewer.