1 | AT_BANNER([MoleCuilder - standard options])
|
---|
2 | # 1. verbosity
|
---|
3 | AT_SETUP([Standard Options - verbosity with Undo/Redo])
|
---|
4 | AT_KEYWORDS([options])
|
---|
5 | AT_CHECK([pwd],[ignore],[ignore])
|
---|
6 | AT_CHECK([../../molecuilder -v 9], 0, [stdout], [ignore])
|
---|
7 | AT_CHECK([grep "Setting verbosity from .* to 9" stdout], 0, [ignore], [ignore])
|
---|
8 | AT_CHECK([../../molecuilder -v 9 --undo], 0, [stdout], [ignore])
|
---|
9 | AT_CHECK([grep "Setting verbosity from 9 to .*" stdout], 0, [ignore], [ignore])
|
---|
10 | AT_CHECK([../../molecuilder -v 9 --undo --redo], 0, [stdout], [ignore])
|
---|
11 | AT_CHECK([grep "Setting verbosity from .* to 9" stdout], 0, [ignore], [ignore])
|
---|
12 | AT_CLEANUP
|
---|
13 |
|
---|
14 | # 2. help screen
|
---|
15 | AT_SETUP([Standard Options - help screen])
|
---|
16 | AT_KEYWORDS([options])
|
---|
17 | AT_CHECK([../../molecuilder -h], 0, [stdout], [ignore])
|
---|
18 | AT_CHECK([fgrep "help screen" stdout], 0, [ignore], [ignore])
|
---|
19 | AT_CHECK([../../molecuilder --help], 0, [stdout], [ignore])
|
---|
20 | AT_CHECK([fgrep "help screen" stdout], 0, [ignore], [ignore])
|
---|
21 | AT_CLEANUP
|
---|
22 | AT_SETUP([Standard Options - warranty screen])
|
---|
23 | AT_KEYWORDS([options])
|
---|
24 | AT_CHECK([../../molecuilder --warranty], 0, [stdout], [ignore])
|
---|
25 | AT_CHECK([fgrep "statement concerning warranty" stdout], 0, [ignore], [ignore])
|
---|
26 | AT_CHECK([fgrep "WITHOUT ANY WARRANTY" stdout], 0, [ignore], [ignore])
|
---|
27 | AT_CLEANUP
|
---|
28 |
|
---|
29 | # 3. no element database
|
---|
30 | AT_SETUP([Standard Options - no element database])
|
---|
31 | AT_KEYWORDS([options])
|
---|
32 | AT_CHECK([../../molecuilder -e], 134, [ignore], [stderr])
|
---|
33 | AT_CLEANUP
|
---|
34 |
|
---|
35 | # 4. element database
|
---|
36 | AT_SETUP([Standard Options - element database])
|
---|
37 | AT_KEYWORDS([options])
|
---|
38 | AT_DATA([elements.db], [[# Covalent radius of each element in Angstroem from CSD (binding is: [Rcov(A)+Rcov(B)-t,Rcov(A)+Rcov(B)+t] with t = 0.4A
|
---|
39 | #Element Name Symbol Period Group Block Atomic Number AtomicWeight Covalent Radius vdW Radius
|
---|
40 | Hydrogen H 1 1 s 1 1.008 0.23 1.09
|
---|
41 | Helium He 1 18 p 2 4.003 1.5 1.4
|
---|
42 | ]])
|
---|
43 | AT_CHECK([../../molecuilder -i test.conf -e ./], 0, [stdout], [stderr])
|
---|
44 | AT_CHECK([grep -E "Using.*as elements database." stdout], 0, [ignore], [ignore])
|
---|
45 | AT_CHECK([fgrep "Element list loaded successfully." stdout], 0, [ignore], [ignore])
|
---|
46 | AT_CHECK([fgrep "Something went wrong while parsing the other databases!" stderr], 0, [ignore], [ignore])
|
---|
47 | AT_CLEANUP
|
---|
48 |
|
---|
49 | # 5. bond length database
|
---|
50 | AT_SETUP([Standard Options - bond length table])
|
---|
51 | AT_KEYWORDS([options])
|
---|
52 | AT_DATA([bondlength.db], [[# bond length database
|
---|
53 | 1 2
|
---|
54 | 1 1. 0.
|
---|
55 | 2 0. 0.
|
---|
56 | ]])
|
---|
57 | AT_CHECK([../../molecuilder -i test.conf -g bondlength.db], 0, [stdout], [stderr])
|
---|
58 | AT_CHECK([grep -E "Using.*as bond length table." stdout], 0, [ignore], [ignore])
|
---|
59 | AT_CLEANUP
|
---|
60 |
|
---|
61 | # 6. fast trajectories
|
---|
62 | AT_SETUP([Standard Options - fast trajectories])
|
---|
63 | AT_KEYWORDS([options])
|
---|
64 | AT_CHECK([../../molecuilder -i test.conf -n 1], 0, [stdout], [stderr])
|
---|
65 | AT_CHECK([fgrep "I won't parse trajectories" stdout], 0, [ignore], [ignore])
|
---|
66 | AT_CLEANUP
|
---|
67 | AT_SETUP([Standard Options - fast trajectories with Undo/Redo])
|
---|
68 | AT_KEYWORDS([options])
|
---|
69 | AT_CHECK([../../molecuilder -i test.conf -n 1 --undo], 0, [stdout], [stderr])
|
---|
70 | AT_CHECK([fgrep "I will parse trajectories." stdout], 0, [ignore], [ignore])
|
---|
71 | AT_CHECK([../../molecuilder -i test.conf -n 1 --undo --redo], 0, [stdout], [stderr])
|
---|
72 | AT_CHECK([grep -c "I won't parse trajectories" stdout], 0, 2
|
---|
73 | , [ignore])
|
---|
74 | AT_CLEANUP
|
---|
75 |
|
---|
76 | # 7. molecule default name
|
---|
77 | AT_SETUP([Standard Options - molecule default name])
|
---|
78 | AT_KEYWORDS([options])
|
---|
79 | AT_CHECK([../../molecuilder -i test.conf -X test], 0, [stdout], [stderr])
|
---|
80 | AT_CHECK([fgrep "Default name of new molecules set to test." stdout], 0, [ignore], [ignore])
|
---|
81 | AT_CLEANUP
|
---|
82 | AT_SETUP([Standard Options - molecule default name with Undo/Redo])
|
---|
83 | AT_KEYWORDS([options])
|
---|
84 | AT_CHECK([../../molecuilder -i test.conf -X test --undo], 0, [stdout], [stderr])
|
---|
85 | AT_CHECK([fgrep "Default name of new molecules set to none." stdout], 0, [ignore], [ignore])
|
---|
86 | AT_CHECK([../../molecuilder -i test.conf -X test --undo --redo], 0, [stdout], [stderr])
|
---|
87 | AT_CHECK([fgrep "Default name of new molecules set to test." stdout], 0, [ignore], [ignore])
|
---|
88 | AT_CLEANUP
|
---|