Blink roll 25b6bd3a7a131ffe68d809546ad1a20707915cdc:3a503f41ae42e5b79cfcd2ff10e65afde...
[chromium-blink-merge.git] / third_party / libevent / test / test.sh
blob506a1988c34b6cd59d2ff7dee9043ca5a0a785a0
1 #!/bin/sh
3 setup () {
4 EVENT_NOKQUEUE=yes; export EVENT_NOKQUEUE
5 EVENT_NODEVPOLL=yes; export EVENT_NODEVPOLL
6 EVENT_NOPOLL=yes; export EVENT_NOPOLL
7 EVENT_NOSELECT=yes; export EVENT_NOSELECT
8 EVENT_NOEPOLL=yes; export EVENT_NOEPOLL
9 EVENT_NOEVPORT=yes; export EVENT_NOEVPORT
12 test () {
13 if ./test-init 2>/dev/null ;
14 then
15 true
16 else
17 echo Skipping test
18 return
19 fi
21 echo -n " test-eof: "
22 if ./test-eof >/dev/null ;
23 then
24 echo OKAY ;
25 else
26 echo FAILED ;
28 echo -n " test-weof: "
29 if ./test-weof >/dev/null ;
30 then
31 echo OKAY ;
32 else
33 echo FAILED ;
35 echo -n " test-time: "
36 if ./test-time >/dev/null ;
37 then
38 echo OKAY ;
39 else
40 echo FAILED ;
42 echo -n " regress: "
43 if ./regress >/dev/null ;
44 then
45 echo OKAY ;
46 else
47 echo FAILED ;
51 echo "Running tests:"
53 # Need to do this by hand?
54 setup
55 unset EVENT_NOKQUEUE
56 export EVENT_NOKQUEUE
57 echo "KQUEUE"
58 test
60 setup
61 unset EVENT_NODEVPOLL
62 export EVENT_NODEVPOLL
63 echo "DEVPOLL"
64 test
66 setup
67 unset EVENT_NOPOLL
68 export EVENT_NOPOLL
69 echo "POLL"
70 test
72 setup
73 unset EVENT_NOSELECT
74 export EVENT_NOSELECT
75 echo "SELECT"
76 test
78 setup
79 unset EVENT_NOEPOLL
80 export EVENT_NOEPOLL
81 echo "EPOLL"
82 test
84 setup
85 unset EVENT_NOEVPORT
86 export EVENT_NOEVPORT
87 echo "EVPORT"
88 test