summaryrefslogtreecommitdiffstats
path: root/tests/007-rpmdbinfo.phpt
blob: 4a977d13be230641281d0d7bb2305b2f7a58b88c (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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
--TEST--
Check for rpmdbinfo function on Name
--SKIPIF--
<?php if (!extension_loaded("rpminfo")) print "skip"; ?>
--FILE--
<?php 
var_dump(rpmdbinfo('doesntexistsinrpmdb'));
var_dump(rpmdbinfo('bash'));
var_dump(rpmaddtag(RPMTAG_INSTALLTIME));
var_dump(rpmaddtag(RPMTAG_BUILDTIME));
var_dump(rpmaddtag(RPMTAG_INSTALLTIME));
var_dump(rpmdbinfo('bash'));
?>
Done
--EXPECTF--
NULL
array(1) {
  [0]=>
  array(5) {
    ["Name"]=>
    string(4) "bash"
    ["Version"]=>
    string(%d) "%s"
    ["Release"]=>
    string(%d) "%s"
    ["Summary"]=>
    string(26) "The GNU Bourne Again shell"
    ["Arch"]=>
    string(%d) "%s"
  }
}
bool(true)
bool(true)
bool(false)
array(1) {
  [0]=>
  array(7) {
    ["Name"]=>
    string(4) "bash"
    ["Version"]=>
    string(%d) "%s"
    ["Release"]=>
    string(%d) "%s"
    ["Summary"]=>
    string(26) "The GNU Bourne Again shell"
    ["Buildtime"]=>
    int(%d)
    ["Installtime"]=>
    int(%d)
    ["Arch"]=>
    string(%d) "%s"
  }
}
Done