graphql-php/tests/Language/TokenTest.php

21 lines
426 B
PHP
Raw Normal View History

2017-10-04 18:06:25 +03:00
<?php
namespace GraphQL\Tests;
use GraphQL\Language\Token;
class TokenTest extends \PHPUnit_Framework_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());
}
}