Navigation Menu

Skip to content

Commit

Permalink
Backport test of issue #246 to PHP 5
Browse files Browse the repository at this point in the history
The reference handling issue applied only to PHP 7, nevertheless
run the test against PHP 5 version as well.
  • Loading branch information
stesie committed Aug 11, 2016
1 parent 677c0f3 commit 15cdc3e
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions tests/issue_246_001.phpt
@@ -0,0 +1,18 @@
--TEST--
Test V8::executeString() : Handle Z_TYPE == IS_REFERENCE (issue #246)
--SKIPIF--
<?php
require_once(dirname(__FILE__) . '/skipif.inc');
?>
--FILE--
<?php
$v8 = new V8Js();
$array = ['lorem' => 'ipsum'];
array_walk_recursive($array, function (&$item) {});
$v8->some_array = $array;
$v8->executeString('var_dump(PHP.some_array.lorem);');
?>
===EOF===
--EXPECT--
string(5) "ipsum"
===EOF===

0 comments on commit 15cdc3e

Please sign in to comment.