Add nested Record types

Signed-off-by: davidarendsen <davidarendsen@hey.com>
This commit is contained in:
davidarendsen 2022-08-16 15:28:46 +00:00
commit a3bf698359
3 changed files with 18 additions and 5 deletions

View file

@ -6,6 +6,7 @@ namespace Tests\Type;
use DateTime;
use Arendsen\FluxQueryBuilder\Type;
use Arendsen\FluxQueryBuilder\Type\Record;
use PHPUnit\Framework\TestCase;
final class FactoryTypeTest extends TestCase
@ -59,6 +60,10 @@ final class FactoryTypeTest extends TestCase
['hello' => ['test' => 'bar', 'foo' => 'hi']],
'hello: [test: "bar", foo: "hi"]'
],
'Record' => [
new Record(['foo' => 'bar', 'nested' => ['hello' => 'world']]),
'{foo: "bar", nested: {hello: "world"}}'
],
];
}
}