Revision 570274e4 htest/shelltests/htools-mon-collector.test

b/htest/shelltests/htools-mon-collector.test
2 2
./htest/hpc-mon-collector
3 3
>>>= !0
4 4

  
5
# 2. Test that the drbd collector fails parsing /dev/null
5
# 2. Test that standard options are accepted, both at top level
6
# and subcommands level
7
./htest/hpc-mon-collector --help
8
>>>= 0
9

  
10
./htest/hpc-mon-collector --help-completion
11
>>>= 0
12

  
13
./htest/hpc-mon-collector --version
14
>>>= 0
15

  
16
./htest/hpc-mon-collector drbd --help
17
>>>= 0
18

  
19
./htest/hpc-mon-collector drbd --help-completion
20
>>>= 0
21

  
22
./htest/hpc-mon-collector drbd --version
23
>>>= 0
24

  
25
# 3. Test that the drbd collector fails parsing /dev/null
6 26
./htest/hpc-mon-collector drbd /dev/null
7 27
>>>2
8 28
Error: ""
......
10 30
Failed reading: versionInfo
11 31
>>>= !0
12 32

  
13
# 3. Test that the drbd collector fails parsing /dev/zero, but is not
33
# 4. Test that a non-existent file is correctly reported
34
./htest/hpc-mon-collector drbd /dev/no-such-file
35
>>>2/Error: reading from file: .* does not exist/
36
>>>= !0
37

  
38
# 5. Test that multiple files are rejected
39
./htest/hpc-mon-collector drbd /dev/null /dev/null
40
>>>2/takes only one argument/
41
>>>= !0
42

  
43
# 6. Test that a standard test file is parsed correctly
44
./htest/hpc-mon-collector drbd $PYTESTDATA_DIR/proc_drbd83.txt
45
>>>=0
46

  
47
# 7. Test that the drbd collector fails parsing /dev/zero, but is not
14 48
# stuck forever printing \NUL chars
15 49
./htest/hpc-mon-collector drbd /dev/zero
16 50
>>>2

Also available in: Unified diff