class TokenTest extends MediaWikiTestCase {
public function testBasics() {
- $token = $this->getMockBuilder( 'MediaWiki\\Session\\Token' )
- ->setMethods( array( 'toStringAtTimestamp' ) )
- ->setConstructorArgs( array( 'sekret', 'salty', true ) )
+ $token = $this->getMockBuilder( Token::class )
+ ->setMethods( [ 'toStringAtTimestamp' ] )
+ ->setConstructorArgs( [ 'sekret', 'salty', true ] )
->getMock();
$token->expects( $this->any() )->method( 'toStringAtTimestamp' )
->will( $this->returnValue( 'faketoken+\\' ) );