aboutsummaryrefslogtreecommitdiff
path: root/tests/mocks
diff options
context:
space:
mode:
authorАлександр Кирюхин <alexander@kiryukhin.su>2018-01-19 19:03:26 +0300
committerАлександр Кирюхин <alexander@kiryukhin.su>2018-01-19 19:03:26 +0300
commit8ea647570b87adda400e5a3ce6c91f4b51327a0d (patch)
tree7c5d328b41e64c3e78ac89c9674747346233c87a /tests/mocks
parent47c9d580c6e799e72b6a70b22dd5107790b1d3e9 (diff)
Remove KeyValue objectHEADmaster
Diffstat (limited to 'tests/mocks')
-rw-r--r--tests/mocks/MockCompiler.php11
-rw-r--r--tests/mocks/MockParser.php7
2 files changed, 8 insertions, 10 deletions
diff --git a/tests/mocks/MockCompiler.php b/tests/mocks/MockCompiler.php
index 89db68f..fced5a2 100644
--- a/tests/mocks/MockCompiler.php
+++ b/tests/mocks/MockCompiler.php
@@ -7,7 +7,6 @@ declare(strict_types=1);
*/
use NeonXP\Dotenv\Compiler\CompilerInterface;
-use NeonXP\Dotenv\Types\KeyValue;
/**
* Class MockCompiler
@@ -16,7 +15,7 @@ class MockCompiler implements CompilerInterface
{
/**
- * @param KeyValue[] $collection
+ * @param array[] $collection
*/
function setRawCollection(array $collection): void
{
@@ -24,11 +23,11 @@ class MockCompiler implements CompilerInterface
}
/**
- * @param KeyValue $keyValue
- * @return KeyValue
+ * @param array $array
+ * @return array
*/
- function compileKeyValue(KeyValue $keyValue): KeyValue
+ function compile(array $array): array
{
- return $keyValue;
+ return $array;
}
} \ No newline at end of file
diff --git a/tests/mocks/MockParser.php b/tests/mocks/MockParser.php
index 39c369c..d327f9f 100644
--- a/tests/mocks/MockParser.php
+++ b/tests/mocks/MockParser.php
@@ -7,7 +7,6 @@ declare(strict_types=1);
*/
use NeonXP\Dotenv\Parser\ParserInterface;
-use NeonXP\Dotenv\Types\KeyValue;
/**
* Class MockParser
@@ -17,12 +16,12 @@ class MockParser implements ParserInterface
/**
* @param string $line
- * @return KeyValue
+ * @return array
*/
- public function parseLine(string $line): KeyValue
+ public function parseLine(string $line): array
{
list($key, $value) = explode("=", $line);
- return new KeyValue($key, $value);
+ return ['key' => $key, 'value' => $value];
}
} \ No newline at end of file