[512f85] | 1 | ### 2. (un)select all atoms inside cuboid
|
---|
| 2 |
|
---|
| 3 | AT_SETUP([Selection - All atoms inside cuboid])
|
---|
| 4 | AT_KEYWORDS([selection,cuboid])
|
---|
[23b0c2] | 5 |
|
---|
[512f85] | 6 | file=allatomsoutsidecuboid.xyz
|
---|
[b9bfa6] | 7 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 8 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 9 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 -r], 0, [stdout], [stderr])
|
---|
[23b0c2] | 10 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsoutsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 11 |
|
---|
[e69c87] | 12 | # check size of cuboid
|
---|
| 13 | AT_SKIP_IF([! awk '' < /dev/null]) # check whether awk is there
|
---|
| 14 | AT_SKIP_IF([! cat >/dev/null < /dev/null]) # check whether cat is there
|
---|
| 15 | AT_SKIP_IF([! wc -l /dev/null]) # check whether wc is there
|
---|
| 16 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 > 10) || ($3 > 10) || ($4 > 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 17 | AT_CHECK([fgrep "838" stdout], 0, [ignore], [ignore])
|
---|
| 18 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 < 10) && ($3 < 10) && ($4 < 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 19 | AT_CHECK([fgrep "1" stdout], 0, [ignore], [ignore])
|
---|
| 20 |
|
---|
| 21 | AT_CLEANUP
|
---|
| 22 |
|
---|
| 23 |
|
---|
| 24 | AT_SETUP([Selection - All atoms inside cuboid with Undo])
|
---|
| 25 | AT_KEYWORDS([selection,cuboid])
|
---|
| 26 |
|
---|
[23b0c2] | 27 | file=allatomsoutsidecuboid.xyz
|
---|
[b9bfa6] | 28 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 29 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 30 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 --undo -r], 0, [stdout], [stderr])
|
---|
[b9bfa6] | 31 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz], 0, [ignore], [ignore])
|
---|
[23b0c2] | 32 |
|
---|
[e69c87] | 33 | AT_CLEANUP
|
---|
| 34 |
|
---|
| 35 |
|
---|
| 36 | AT_SETUP([Selection - All atoms inside cuboid with Redo])
|
---|
| 37 | AT_KEYWORDS([selection,cuboid])
|
---|
| 38 |
|
---|
[23b0c2] | 39 | file=allatomsoutsidecuboid.xyz
|
---|
[b9bfa6] | 40 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 41 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 42 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 --undo --redo -r], 0, [stdout], [stderr])
|
---|
[23b0c2] | 43 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsoutsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 44 |
|
---|
[e69c87] | 45 |
|
---|
| 46 | AT_CLEANUP
|
---|
| 47 |
|
---|
| 48 |
|
---|
| 49 | AT_SETUP([Selection - All atoms inside cuboid with defaults])
|
---|
| 50 | AT_KEYWORDS([selection,cuboid])
|
---|
| 51 |
|
---|
| 52 | file=allatomsoutsidecuboid.xyz
|
---|
| 53 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
| 54 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 55 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" -r], 0, [stdout], [stderr])
|
---|
| 56 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsoutsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 57 |
|
---|
[512f85] | 58 | # check size of cuboid
|
---|
| 59 | AT_SKIP_IF([! awk '' < /dev/null]) # check whether awk is there
|
---|
| 60 | AT_SKIP_IF([! cat >/dev/null < /dev/null]) # check whether cat is there
|
---|
| 61 | AT_SKIP_IF([! wc -l /dev/null]) # check whether wc is there
|
---|
| 62 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 > 10) || ($3 > 10) || ($4 > 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 63 | AT_CHECK([fgrep "838" stdout], 0, [ignore], [ignore])
|
---|
| 64 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 < 10) && ($3 < 10) && ($4 < 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 65 | AT_CHECK([fgrep "1" stdout], 0, [ignore], [ignore])
|
---|
[23b0c2] | 66 |
|
---|
[512f85] | 67 | AT_CLEANUP
|
---|
| 68 |
|
---|
[23b0c2] | 69 |
|
---|
[e69c87] | 70 | AT_SETUP([Selection - All atoms inside cuboid with defaults with Undo])
|
---|
[23d7ff] | 71 | AT_KEYWORDS([selection,cuboid])
|
---|
[23b0c2] | 72 |
|
---|
| 73 | file=allatomsoutsidecuboid.xyz
|
---|
[23d7ff] | 74 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 75 | AT_CHECK([chmod u+w $file], 0)
|
---|
[23d7ff] | 76 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" --undo -r], 0, [stdout], [stderr])
|
---|
| 77 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz], 0, [ignore], [ignore])
|
---|
[23b0c2] | 78 |
|
---|
[e69c87] | 79 | AT_CLEANUP
|
---|
| 80 |
|
---|
| 81 |
|
---|
| 82 | AT_SETUP([Selection - All atoms inside cuboid with defaults with Redo])
|
---|
| 83 | AT_KEYWORDS([selection,cuboid])
|
---|
| 84 |
|
---|
[23b0c2] | 85 | file=allatomsoutsidecuboid.xyz
|
---|
[23d7ff] | 86 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 87 | AT_CHECK([chmod u+w $file], 0)
|
---|
[23d7ff] | 88 | AT_CHECK([../../molecuilder -i $file -v 5 --select-atoms-inside-cuboid "10,10,10" --position "0,0,0" --undo --redo -r], 0, [stdout], [stderr])
|
---|
[23b0c2] | 89 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsoutsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 90 |
|
---|
| 91 |
|
---|
[23d7ff] | 92 | AT_CLEANUP
|
---|
| 93 |
|
---|
[23b0c2] | 94 |
|
---|
[512f85] | 95 | AT_SETUP([Unselection - All atoms inside cuboid])
|
---|
| 96 | AT_KEYWORDS([selection,cuboid])
|
---|
[23b0c2] | 97 |
|
---|
[512f85] | 98 | file=allatomsinsidecuboid.xyz
|
---|
[b9bfa6] | 99 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 100 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 101 | AT_CHECK([../../molecuilder -i $file -v 5 --select-all-atoms --unselect-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 -r], 0, [stdout], [stderr])
|
---|
[23b0c2] | 102 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsinsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 103 |
|
---|
[e69c87] | 104 | # check size of cuboid
|
---|
| 105 | AT_SKIP_IF([! awk '' < /dev/null]) # check whether awk is there
|
---|
| 106 | AT_SKIP_IF([! cat >/dev/null < /dev/null]) # check whether cat is there
|
---|
| 107 | AT_SKIP_IF([! wc -l /dev/null]) # check whether wc is there
|
---|
| 108 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 < 10) || ($3 < 10) || ($4 < 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 109 | AT_CHECK([fgrep "193" stdout], 0, [ignore], [ignore])
|
---|
| 110 | AT_CHECK([cat < $file | awk -F" " '{ if (($2 > 10) && ($3 > 10) && ($4 > 10)) print $1,$2,$3,$4;}' | wc -l], 0, [stdout], [ignore])
|
---|
| 111 | AT_CHECK([fgrep "1" stdout], 0, [ignore], [ignore])
|
---|
| 112 |
|
---|
| 113 | AT_CLEANUP
|
---|
| 114 |
|
---|
| 115 |
|
---|
| 116 | AT_SETUP([Unselection - All atoms inside cuboid with Undo])
|
---|
| 117 | AT_KEYWORDS([selection,cuboid])
|
---|
| 118 |
|
---|
[23b0c2] | 119 | file=allatomsinsidecuboid.xyz
|
---|
[b9bfa6] | 120 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 121 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 122 | AT_CHECK([../../molecuilder -i $file -v 5 --select-all-atoms --unselect-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 --undo -r], 0, [stdout], [stderr])
|
---|
[b9bfa6] | 123 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/empty.xyz], 0, [ignore], [ignore])
|
---|
[23b0c2] | 124 |
|
---|
[e69c87] | 125 | AT_CLEANUP
|
---|
| 126 |
|
---|
| 127 |
|
---|
| 128 | AT_SETUP([Unselection - All atoms inside cuboid with Redo])
|
---|
| 129 | AT_KEYWORDS([selection,cuboid])
|
---|
| 130 |
|
---|
[23b0c2] | 131 | file=allatomsinsidecuboid.xyz
|
---|
[b9bfa6] | 132 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/pre/box.xyz $file], 0)
|
---|
[23b0c2] | 133 | AT_CHECK([chmod u+w $file], 0)
|
---|
[512f85] | 134 | AT_CHECK([../../molecuilder -i $file -v 5 --select-all-atoms --unselect-atoms-inside-cuboid "10,10,10" --position "0,0,0" --angle-x 0 --angle-y 0 --angle-z 0 --undo --redo -r], 0, [stdout], [stderr])
|
---|
[23b0c2] | 135 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/${AUTOTEST_PATH}/Selection/Atoms/AtomsInsideCuboid/post/allatomsinsidecuboid.xyz], 0, [ignore], [ignore])
|
---|
| 136 |
|
---|
[512f85] | 137 | AT_CLEANUP
|
---|