diff options
-rw-r--r-- | tests/lib/Accounts/AccountManagerTest.php | 31 |
1 files changed, 27 insertions, 4 deletions
diff --git a/tests/lib/Accounts/AccountManagerTest.php b/tests/lib/Accounts/AccountManagerTest.php index 23a2cd7d996..518a0f37a16 100644 --- a/tests/lib/Accounts/AccountManagerTest.php +++ b/tests/lib/Accounts/AccountManagerTest.php @@ -786,20 +786,41 @@ class AccountManagerTest extends TestCase { '@foo@example.com', 'foo@example.com', true, - json_encode(['username' => 'foo']), + json_encode([ + 'subject' => 'acct:foo@example.com', + 'links' => [ + [ + 'rel' => 'self', + 'type' => 'application/activity+json', + 'href' => 'https://example.com/users/foo', + ], + ], + ]), ], 'valid response - no at' => [ 'foo@example.com', 'foo@example.com', true, - json_encode(['username' => 'foo']), + json_encode([ + 'subject' => 'acct:foo@example.com', + 'links' => [ + [ + 'rel' => 'self', + 'type' => 'application/activity+json', + 'href' => 'https://example.com/users/foo', + ], + ], + ]), ], // failures 'invalid response' => [ '@foo@example.com', null, true, - json_encode(['not found']), + json_encode([ + 'subject' => 'acct:foo@example.com', + 'links' => [], + ]), ], 'no response' => [ '@foo@example.com', @@ -811,7 +832,9 @@ class AccountManagerTest extends TestCase { '@foo@example.com', null, true, - json_encode(['username' => 'foo@other.example.com']), + json_encode([ + 'links' => [], + ]), ], ]; } |