summaryrefslogtreecommitdiff
path: root/tests/rpmio.at
blob: 35abd9475842711e308262625f606b472e065878 (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
55
56
57
58
59
60
61
#    rpmio.at: Misc (librpm)io tests

AT_BANNER([I/O])

# test too unstable for production
#AT_SETUP([SIGPIPE from --pipe])
#AT_KEYWORDS([signals])
#AT_CHECK([
#RPMDB_CLEAR
#RPMDB_INIT
#
#runroot rpmbuild --quiet --with manyfiles -bb /data/SPECS/sigpipe.spec
#runroot rpm -qpl /build/RPMS/noarch/sigpipe-1.0-1.noarch.rpm --pipe "cat" | head -1
#],
#[0],
#[/opt/sigpipe/data
#],
#[])
#AT_CLEANUP

AT_SETUP([SIGPIPE from install scriptlet])
AT_KEYWORDS([signals])
AT_CHECK([
RPMDB_INIT

runroot rpmbuild --quiet -bb /data/SPECS/sigpipe.spec
runroot rpm -U --nodeps /build/RPMS/noarch/sigpipe-1.0-1.noarch.rpm
],
[0],
[],
[])
AT_CLEANUP

# XXX TODO: test for RhBug:471591 too, but needs a simpler reproducer

# test too unstable for production
#AT_SETUP([SIGPIPE in build scriptlet])
#AT_KEYWORDS([signals])
#AT_CHECK([
#RPMDB_CLEAR
#RPMDB_INIT
#
#run rpmbuild --quiet --with buildpipe -bb "${RPMDATA}/SPECS/sigpipe.spec"
#],
#[0],
#[],
#[])
#AT_CLEANUP

AT_SETUP([rpmlog error handling])
AT_KEYWORDS([log])
AT_CHECK([
RPMDB_INIT

runroot rpm -qpl /data/RPMS/hello-2.0-1.x86_64.rpm > /dev/full
],
[0],
[],
[Error writing to log: No space left on device
])
AT_CLEANUP