Add sanity check test for StringWrapper trait
This commit is contained in:
parent
7e705289df
commit
9a4ff3e2e0
|
@ -0,0 +1,26 @@
|
||||||
|
<?php declare(strict_types=1);
|
||||||
|
|
||||||
|
namespace Aviat\Ion\Tests;
|
||||||
|
|
||||||
|
use Aviat\Ion\StringWrapper;
|
||||||
|
use Aviat\Ion\Type\StringType;
|
||||||
|
use PHPUnit\Framework\TestCase;
|
||||||
|
|
||||||
|
class StringWrapperTest extends TestCase {
|
||||||
|
|
||||||
|
protected $wrapper;
|
||||||
|
|
||||||
|
public function setUp()
|
||||||
|
{
|
||||||
|
$this->wrapper = new class {
|
||||||
|
use StringWrapper;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
public function testString()
|
||||||
|
{
|
||||||
|
$str = $this->wrapper->string('foo');
|
||||||
|
$this->assertInstanceOf(StringType::class, $str);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue