public function testCommandFailedCreatesExpectedMessage() { $exception = new UserAlreadyExistsException("foo bar baz"); $expectedMessage = 'Command failed: League\\Tactician\\Logger\\Tests\\Fixtures\\RegisterUserCommand threw the exception ' . UserAlreadyExistsException::class . ' (foo bar baz)'; $this->assertEquals($expectedMessage, $this->formatter->commandFailed(new RegisterUserCommand(), $exception)); }
public function testCommandFailedCreatesExpectedMessage() { $exception = new UserAlreadyExistsException("foo bar baz"); $expectedMessage = 'Command failed: ' . RegisterUserCommand::class . ' threw the exception ' . UserAlreadyExistsException::class . ' (foo bar baz)'; $this->assertEquals($expectedMessage, $this->formatter->commandFailed(new RegisterUserCommand(), $exception)); }