From a8582bcbf0af55cd634f254e3a8e43fd4e0378e4 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 5 Feb 2019 09:58:37 +0100 Subject: fix FTBFS with PHP 7.3, patch from https://github.com/zendframework/zend-config/pull/54 use range dependencies --- 27d5ba5c13cb4a576400f534057b69231190ac9d.patch | 43 ++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 27d5ba5c13cb4a576400f534057b69231190ac9d.patch (limited to '27d5ba5c13cb4a576400f534057b69231190ac9d.patch') diff --git a/27d5ba5c13cb4a576400f534057b69231190ac9d.patch b/27d5ba5c13cb4a576400f534057b69231190ac9d.patch new file mode 100644 index 0000000..5899ffb --- /dev/null +++ b/27d5ba5c13cb4a576400f534057b69231190ac9d.patch @@ -0,0 +1,43 @@ +From 27d5ba5c13cb4a576400f534057b69231190ac9d Mon Sep 17 00:00:00 2001 +From: webimpress +Date: Sun, 16 Dec 2018 12:23:02 +0000 +Subject: [PATCH] Fixed expected value in test to work on PHP 7.3 + +Result of var_export for object has been changed on PHP 7.3 +See: https://bugs.php.net/bug.php?id=48016 +--- + test/Writer/PhpArrayTest.php | 14 +++++++++++--- + 1 file changed, 11 insertions(+), 3 deletions(-) + +diff --git a/test/Writer/PhpArrayTest.php b/test/Writer/PhpArrayTest.php +index e3e0420..df4523e 100644 +--- a/test/Writer/PhpArrayTest.php ++++ b/test/Writer/PhpArrayTest.php +@@ -41,6 +41,16 @@ public function testRender() + + $configString = $this->writer->toString($config); + ++ $object = "stdClass::__set_state(array(\n" ++ . " 'foo' => 'bar',\n" ++ . ')),'; ++ ++ if (version_compare(PHP_VERSION, '7.3.0') !== -1) { ++ $object = '(object) array(' . "\n" ++ . " 'foo' => 'bar',\n" ++ . '),'; ++ } ++ + // build string line by line as we are trailing-whitespace sensitive. + $expected = " 'foo',\n"; + $expected .= " ),\n"; + $expected .= " 'emptyArray' => array(),\n"; +- $expected .= " 'object' => stdClass::__set_state(array(\n"; +- $expected .= " 'foo' => 'bar',\n"; +- $expected .= ")),\n"; ++ $expected .= " 'object' => " . $object . "\n"; + $expected .= " 'integer' => 123,\n"; + $expected .= " 'boolean' => false,\n"; + $expected .= " 'null' => null,\n"; -- cgit