for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of the Cubiche/EventSourcing component.
*
* Copyright (c) Cubiche
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Cubiche\Domain\EventSourcing\Tests\Units\Utils;
use Cubiche\Domain\EventSourcing\Tests\Fixtures\PostEventSourced;
use Cubiche\Domain\EventSourcing\Tests\Units\TestCase;
use Cubiche\Domain\EventSourcing\Utils\NameResolver;
use Cubiche\Domain\Model\Tests\Fixtures\PostId;
* NameResolverTests class.
* Generated by TestGenerator on 2016-07-26 at 14:15:46.
class NameResolverTests extends TestCase
{
* Test Resolve method.
public function testResolve()
$this
->given($className = PostEventSourced::class)
->and($postId = PostId::fromNative(md5(rand())))
->when($result = NameResolver::resolve($className, $postId))
->then()
->string($result)
->isEqualTo('PostEventSourced-'.$postId->toNative())
;
->given($className = 'FooDocument')
->isEqualTo('FooDocument-'.$postId->toNative())
}