for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of the Cubiche package.
*
* Copyright (c) Cubiche
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Cubiche\Core\Bus\Tests\Units\Middlewares\Handler\Resolver\HandlerMethodName;
use Cubiche\Core\Bus\Middlewares\Handler\Resolver\HandlerMethodName\MethodWithObjectNameResolver;
use Cubiche\Core\Bus\Tests\Fixtures\Command\LoginUserCommand;
use Cubiche\Core\Bus\Tests\Fixtures\Query\PublishedPostsQuery;
use Cubiche\Core\Bus\Tests\Units\TestCase;
* MethodWithObjectNameResolverTests class.
* @author Ivannis Suárez Jerez <[email protected]>
class MethodWithObjectNameResolverTests extends TestCase
{
* Test Resolve method.
public function testResolve()
$this
->given($resolver = new MethodWithObjectNameResolver())
->when($result = $resolver->resolve(LoginUserCommand::class))
->then()
->string($result)
->isEqualTo('loginUserCommand')
;
->when($result = $resolver->resolve(PublishedPostsQuery::class))
->isEqualTo('publishedPostsQuery')
}