Skip to content

Commit 10cbc92

Browse files
committed
ext/snmp: Remove bool type coercions in tests
1 parent c251952 commit 10cbc92

File tree

2 files changed

+5
-39
lines changed

2 files changed

+5
-39
lines changed

ext/snmp/tests/snmp-object-properties.phpt

Lines changed: 3 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,6 @@ $session->oid_increasing_check = FALSE;
3232

3333
var_dump($session);
3434

35-
$session->max_oids = "40";
36-
$session->enum_print = "1";
37-
$session->quick_print = "1";
38-
$session->valueretrieval = "1";
39-
$session->oid_output_format = "3";
40-
$session->oid_increasing_check = "45";
41-
42-
var_dump($session);
43-
4435
var_dump(property_exists($session, "enum_print"));
4536
var_dump(isset($session->enum_print));
4637
var_dump(empty($session->enum_print));
@@ -93,15 +84,15 @@ object(SNMP)#%d (%d) {
9384
["max_oids"]=>
9485
NULL
9586
["valueretrieval"]=>
96-
int(1)
87+
int(0)
9788
["quick_print"]=>
9889
bool(false)
9990
["enum_print"]=>
10091
bool(false)
10192
["oid_output_format"]=>
102-
int(3)
93+
int(4)
10394
["oid_increasing_check"]=>
104-
bool(true)
95+
bool(false)
10596
["exceptions_enabled"]=>
10697
int(0)
10798
}
@@ -130,31 +121,6 @@ object(SNMP)#%d (%d) {
130121
["exceptions_enabled"]=>
131122
int(0)
132123
}
133-
object(SNMP)#%d (%d) {
134-
["info"]=>
135-
array(3) {
136-
["hostname"]=>
137-
string(%d) "%s"
138-
["timeout"]=>
139-
int(%i)
140-
["retries"]=>
141-
int(%d)
142-
}
143-
["max_oids"]=>
144-
int(40)
145-
["valueretrieval"]=>
146-
int(1)
147-
["quick_print"]=>
148-
bool(true)
149-
["enum_print"]=>
150-
bool(true)
151-
["oid_output_format"]=>
152-
int(3)
153-
["oid_increasing_check"]=>
154-
bool(true)
155-
["exceptions_enabled"]=>
156-
int(0)
157-
}
158124
bool(true)
159125
bool(true)
160126
bool(false)

ext/snmp/tests/snmp_set_enum_print.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ if (!function_exists('snmp_set_enum_print')) die('skip This function is only ava
1414
require_once(__DIR__.'/snmp_include.inc');
1515

1616
echo "Checking working\n";
17-
var_dump(snmp_set_enum_print(0));
18-
var_dump(snmp_set_enum_print(1));
17+
var_dump(snmp_set_enum_print(false));
18+
var_dump(snmp_set_enum_print(true));
1919
?>
2020
--EXPECT--
2121
Checking working

0 commit comments

Comments
 (0)