blob: 2d5c220c93d2ce5a14a292e7235b30ac7ae714a8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
--TEST--
Check for rpmvercmp function error
--SKIPIF--
<?php
if (!extension_loaded("rpminfo")) print "skip";
if (PHP_VERSION_ID >= 80000) print "skip only for PHP 7";
?>
--FILE--
<?php
var_dump(rpmvercmp());
var_dump(rpmvercmp("a"));
var_dump(rpmvercmp("a", "b", "c"));
var_dump(rpmvercmp("a", "b", "c", "d"));
?>
Done
--EXPECTF--
Warning: rpmvercmp() expects at least 2 parameters, 0 given in %s
NULL
Warning: rpmvercmp() expects at least 2 parameters, 1 given in %s
NULL
Warning: rpmvercmp(): c is not a valid comparison operator in %s
NULL
Warning: rpmvercmp() expects at most 3 parameters, 4 given in %s
NULL
Done
|