@@ 29-49 (lines=21) @@ | ||
26 | /** |
|
27 | * @covers \AmericanExpress\HyperledgerFabricClient\Serializer\AsciiCharStringSerializer |
|
28 | */ |
|
29 | class AsciiCharStringSerializerTest extends TestCase |
|
30 | { |
|
31 | /** |
|
32 | * @var AsciiCharStringSerializer |
|
33 | */ |
|
34 | private $sut; |
|
35 | ||
36 | protected function setUp() |
|
37 | { |
|
38 | $this->sut = new AsciiCharStringSerializer(); |
|
39 | } |
|
40 | ||
41 | public function testSerialize() |
|
42 | { |
|
43 | $encoded = $this->sut->deserialize('FooBar'); |
|
44 | ||
45 | $decoded = $this->sut->serialize($encoded); |
|
46 | ||
47 | self::assertSame('FooBar', $decoded); |
|
48 | } |
|
49 | } |
|
50 |
@@ 29-49 (lines=21) @@ | ||
26 | /** |
|
27 | * @covers \AmericanExpress\HyperledgerFabricClient\Serializer\SignedCharStringSerializer |
|
28 | */ |
|
29 | class SignedCharStringSerializerTest extends TestCase |
|
30 | { |
|
31 | /** |
|
32 | * @var SignedCharStringSerializer |
|
33 | */ |
|
34 | private $sut; |
|
35 | ||
36 | protected function setUp() |
|
37 | { |
|
38 | $this->sut = new SignedCharStringSerializer(); |
|
39 | } |
|
40 | ||
41 | public function testSerialize() |
|
42 | { |
|
43 | $encoded = $this->sut->deserialize('FooBar'); |
|
44 | ||
45 | $decoded = $this->sut->serialize($encoded); |
|
46 | ||
47 | self::assertSame('FooBar', $decoded); |
|
48 | } |
|
49 | } |
|
50 |