aboutsummaryrefslogtreecommitdiffstats
path: root/tests/phpunit/includes/user/UserTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/phpunit/includes/user/UserTest.php')
-rw-r--r--tests/phpunit/includes/user/UserTest.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/phpunit/includes/user/UserTest.php b/tests/phpunit/includes/user/UserTest.php
index 3d1c0f4442bb..5eb3cc719c02 100644
--- a/tests/phpunit/includes/user/UserTest.php
+++ b/tests/phpunit/includes/user/UserTest.php
@@ -709,9 +709,11 @@ class UserTest extends MediaWikiIntegrationTestCase {
$user->saveSettings();
$this->assertSame(
$user->getName(),
- $this->db->selectField(
- 'actor', 'actor_name', [ 'actor_id' => $user->getActorId() ], __METHOD__
- ),
+ $this->db->newSelectQueryBuilder()
+ ->select( 'actor_name' )
+ ->from( 'actor' )
+ ->where( [ 'actor_id' => $user->getActorId() ] )
+ ->caller( __METHOD__ )->fetchField(),
'User::saveSettings updates actor table for name change'
);