mirror of
https://github.com/retailcrm/graphql-php.git
synced 2024-11-25 14:26:08 +03:00
22 lines
439 B
PHP
22 lines
439 B
PHP
<?php
|
|
namespace GraphQL\Tests;
|
|
|
|
use GraphQL\Language\Token;
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
class TokenTest extends TestCase
|
|
{
|
|
public function testReturnTokenOnArray()
|
|
{
|
|
$token = new Token('Kind', 1, 10, 3, 5);
|
|
$expected = [
|
|
'kind' => 'Kind',
|
|
'value' => null,
|
|
'line' => 3,
|
|
'column' => 5
|
|
];
|
|
|
|
$this->assertEquals($expected, $token->toArray());
|
|
}
|
|
}
|