Debian Codegraph @

extensions/Echo/tests/phpunit/integration/Push/UtilsTest.php

raw symbols SCIP
1 <?php
2
3 namespace MediaWiki\Extension\Notifications\Test\Integration\Push;
4
5 use MediaWiki\Extension\Notifications\Push\Utils;
6 use MediaWikiIntegrationTestCase;
7
8 /**
9 * @covers \MediaWiki\Extension\Notifications\Push\Utils
10 * @group Database
11 */
12 class UtilsTest extends MediaWikiIntegrationTestCase {
13
14 public function testGetLoggedInPushId(): void {
15 $user = $this->getTestUser()->getUser();
16 $this->assertGreaterThan( 0, Utils::getPushUserId( $user ) );
17 }
18
19 public function testGetLoggedOutPushId(): void {
20 $user = $this->getTestUser()->getUser();
21 $user->doLogout();
22 $this->assertSame( 0, Utils::getPushUserId( $user ) );
23 }
24
25 }