derived_class_properties_protected.phpt 572 B

123456789101112131415161718192021222324252627
  1. --TEST--
  2. Test V8::executeString() : Protected and private properties on derived class
  3. --SKIPIF--
  4. <?php require_once(dirname(__FILE__) . '/skipif.inc'); ?>
  5. --FILE--
  6. <?php
  7. class V8Wrapper extends V8Js {
  8. protected $testing;
  9. private $privTesting;
  10. public function __construct() {
  11. parent::__construct();
  12. $this->testing = 23;
  13. $this->privTesting = 42;
  14. }
  15. }
  16. $v8 = new V8Wrapper();
  17. $v8->executeString('print(PHP.testing + "\n");');
  18. $v8->executeString('print(PHP.privTesting + "\n");');
  19. ?>
  20. ===EOF===
  21. --EXPECT--
  22. undefined
  23. undefined
  24. ===EOF===