Skip to content
This repository was archived by the owner on Mar 29, 2024. It is now read-only.

Commit 41e5853

Browse files
committed
Add test for V8\AccessControl class
1 parent 9b1cdac commit 41e5853

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

tests/V8AccessControl.phpt

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
--TEST--
2+
V8\AccessControl
3+
--SKIPIF--
4+
<?php if (!extension_loaded("v8")) print "skip"; ?>
5+
--FILE--
6+
<?php
7+
8+
// Bootstraps:
9+
$obj = new V8\AccessControl();
10+
11+
// Tests:
12+
13+
/** @var \Phpv8Testsuite $helper */
14+
$helper = require '.testsuite.php';
15+
16+
$helper->header('Object representation');
17+
$helper->dump($obj);
18+
$helper->space();
19+
20+
21+
$helper->header('Class constants');
22+
$helper->dump_object_constants($obj);
23+
$helper->space();
24+
25+
?>
26+
--EXPECT--
27+
Object representation:
28+
----------------------
29+
object(V8\AccessControl)#1 (0) {
30+
}
31+
32+
33+
Class constants:
34+
----------------
35+
V8\AccessControl::DEFAULT_ACCESS = 0
36+
V8\AccessControl::ALL_CAN_READ = 1
37+
V8\AccessControl::ALL_CAN_WRITE = 2

0 commit comments

Comments
 (0)