mirror of
https://github.com/danog/Valinor.git
synced 2024-12-15 18:37:02 +01:00
23 lines
612 B
PHP
23 lines
612 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace CuyZ\Valinor\Tests\Unit\Mapper\Tree\Builder;
|
|
|
|
use AssertionError;
|
|
use CuyZ\Valinor\Mapper\Tree\Builder\RootNodeBuilder;
|
|
use CuyZ\Valinor\Mapper\Tree\Builder\ScalarNodeBuilder;
|
|
use CuyZ\Valinor\Mapper\Tree\Shell;
|
|
use CuyZ\Valinor\Tests\Fake\Type\FakeType;
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
final class ScalarNodeBuilderTest extends TestCase
|
|
{
|
|
public function test_invalid_type_fails_assertion(): void
|
|
{
|
|
$this->expectException(AssertionError::class);
|
|
|
|
(new RootNodeBuilder(new ScalarNodeBuilder()))->build(Shell::root(new FakeType(), []));
|
|
}
|
|
}
|