1 | ### Removing atoms inside and outside of cuboid
|
---|
2 |
|
---|
3 | AT_SETUP([Atoms - Removing cuboid of atoms])
|
---|
4 | AT_KEYWORDS([atoms,remove-atom])
|
---|
5 |
|
---|
6 | file=test-withoutcuboid.xyz
|
---|
7 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
8 | AT_CHECK([chmod u+w $file], 0)
|
---|
9 | AT_CHECK([../../molecuilder -i $file --select-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r], 0, [stdout], [stderr])
|
---|
10 | AT_CHECK([sort -n $file | grep -v -E "^[[[:digit:]]]+" | grep -v "Created by" >test-withoutcuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
11 | AT_CHECK([file=test-withoutcuboid.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test-withoutcuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
12 |
|
---|
13 | file=test-cuboid.xyz
|
---|
14 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
15 | AT_CHECK([chmod u+w $file], 0)
|
---|
16 | AT_CHECK([../../molecuilder -i $file --select-all-atoms --unselect-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r], 0, [stdout], [stderr])
|
---|
17 | AT_CHECK([sort -n $file | grep -v -E "^[[[:digit:]]]+" | grep -v "Created by" >test-cuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
18 | AT_CHECK([file=test-cuboid.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test-cuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
19 | AT_CHECK([cat test-cuboid.xyz-sorted test-withoutcuboid.xyz-sorted | sort -n >test.xyz-sorted], 0, [ignore], [ignore])
|
---|
20 | AT_CHECK([file=test.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test.xyz-sorted], 0, [ignore], [ignore])
|
---|
21 |
|
---|
22 | AT_CLEANUP
|
---|
23 |
|
---|
24 |
|
---|
25 | AT_SETUP([Atoms - Removing cuboid of atoms with Undo])
|
---|
26 | AT_KEYWORDS([atoms,remove-atom,undo])
|
---|
27 |
|
---|
28 | file=test.xyz
|
---|
29 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
30 | AT_CHECK([chmod u+w $file], 0)
|
---|
31 | AT_CHECK([../../molecuilder -i $file --select-all-atoms --unselect-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r --undo], 0, [stdout], [stderr])
|
---|
32 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/$file], 0, [ignore], [ignore])
|
---|
33 |
|
---|
34 | file=test.xyz
|
---|
35 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
36 | AT_CHECK([chmod u+w $file], 0)
|
---|
37 | AT_CHECK([../../molecuilder -i $file --select-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r --undo], 0, [stdout], [stderr])
|
---|
38 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/$file], 0, [ignore], [ignore])
|
---|
39 |
|
---|
40 | AT_CLEANUP
|
---|
41 |
|
---|
42 |
|
---|
43 | AT_SETUP([Atoms - Removing cuboid of atoms with Redo])
|
---|
44 | AT_KEYWORDS([atoms,remove-atom,redo])
|
---|
45 |
|
---|
46 | file=test-withoutcuboid.xyz
|
---|
47 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
48 | AT_CHECK([chmod u+w $file], 0)
|
---|
49 | AT_CHECK([../../molecuilder -i $file --select-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r --undo --redo], 0, [stdout], [stderr])
|
---|
50 | AT_CHECK([sort -n $file | grep -v -E "^[[[:digit:]]]+" | grep -v "Created by" >test-withoutcuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
51 | AT_CHECK([file=test-withoutcuboid.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test-withoutcuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
52 |
|
---|
53 | file=test-cuboid.xyz
|
---|
54 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/pre/test.xyz $file], 0)
|
---|
55 | AT_CHECK([chmod u+w $file], 0)
|
---|
56 | AT_CHECK([../../molecuilder -i $file --select-all-atoms --unselect-atoms-inside-cuboid "2,2,2" --position "9.78,2.64,2.64" --angle-x 0. --angle-y 0. --angle-z 0. -r --undo --redo], 0, [stdout], [stderr])
|
---|
57 | AT_CHECK([sort -n $file | grep -v -E "^[[[:digit:]]]+" | grep -v "Created by" >test-cuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
58 | AT_CHECK([file=test-cuboid.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test-cuboid.xyz-sorted], 0, [ignore], [ignore])
|
---|
59 | AT_CHECK([cat test-cuboid.xyz-sorted test-withoutcuboid.xyz-sorted | sort -n >test.xyz-sorted], 0, [ignore], [ignore])
|
---|
60 | AT_CHECK([file=test.xyz-sorted; diff $file ${abs_top_srcdir}/tests/regression/Atoms/RemoveCuboid/post/test.xyz-sorted], 0, [ignore], [ignore])
|
---|
61 |
|
---|
62 | AT_CLEANUP
|
---|