1
0
mirror of https://github.com/halaxa/json-machine.git synced 2025-07-16 20:16:25 +02:00
Files
json-machine/test/JsonMachineTest/JsonDecoder/InvalidResultTest.php
2022-02-03 21:56:47 +01:00

29 lines
553 B
PHP

<?php
declare(strict_types=1);
namespace JsonMachineTest\JsonDecoder;
use JsonMachine\JsonDecoder\InvalidResult;
use PHPUnit\Framework\TestCase;
/**
* @covers \JsonMachine\JsonDecoder\InvalidResult
*/
class InvalidResultTest extends TestCase
{
public function testGetErrorMessage()
{
$result = new InvalidResult('Error X');
$this->assertSame('Error X', $result->getErrorMessage());
}
public function testIsOk()
{
$result = new InvalidResult('X');
$this->assertFalse($result->isOk());
}
}