Skip to content

Commit da52724

Browse files
committed
wip
1 parent 4869812 commit da52724

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

tests/Coder/CoderTestCase.php

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,24 +5,32 @@
55
namespace PetrKnap\Binary\Coder;
66

77
use LogicException;
8+
use PetrKnap\Binary\DecoderTest;
9+
use PetrKnap\Binary\EncoderTest;
810
use PetrKnap\Binary\TestCase;
911

1012
abstract class CoderTestCase extends TestCase
1113
{
12-
public const DATA_BASE64 = '2jmj7l5rSw0yVb/vlWAYkK/YBwnaOaPuXmtLDTJVv++VYBiQr9gHCdo5o+5ea0sNMlW/75VgGJCv2AcJ';
13-
14-
abstract public static function data(): array;
14+
protected const DATA_BASE64 = '2jmj7l5rSw0yVb/vlWAYkK/YBwnaOaPuXmtLDTJVv++VYBiQr9gHCdo5o+5ea0sNMlW/75VgGJCv2AcJ';
1515

16+
/**
17+
* @internal reused in {@see EncoderTest} and {@see DecoderTest}
18+
*/
1619
public static function getDecodedData(): string
1720
{
1821
return base64_decode(self::DATA_BASE64);
1922
}
2023

24+
/**
25+
* @internal reused in {@see EncoderTest} and {@see DecoderTest}
26+
*/
2127
public static function getEncodedData(): string
2228
{
2329
foreach (static::data() as $data) {
2430
return $data[1];
2531
}
2632
throw new LogicException('Empty data set.');
2733
}
34+
35+
abstract public static function data(): array;
2836
}

0 commit comments

Comments
 (0)