[61c364] | 1 | ### 6. (un)select atom by order
|
---|
| 2 |
|
---|
| 3 |
|
---|
| 4 | AT_SETUP([Unselection - atom with specific order])
|
---|
| 5 | AT_KEYWORDS([unselection order atom unselect-atom-by-order])
|
---|
| 6 | # go through all possible orders (0-7) and remove others
|
---|
| 7 | i=1
|
---|
| 8 | while test $i -le 8; do
|
---|
| 9 | let id=$i-1
|
---|
| 10 | file=order${id}_present.xyz
|
---|
| 11 | # normal
|
---|
| 12 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 13 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 14 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order ${i} -r], [], [ignore], [ignore])
|
---|
| 15 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/id${id}_present.xyz])
|
---|
| 16 | ((i+=1))
|
---|
| 17 | done
|
---|
| 18 | # go reverse through all possible orders (0-7) and remove others
|
---|
| 19 | i=1
|
---|
| 20 | while test $i -le 8; do
|
---|
| 21 | let id=8-$i
|
---|
| 22 | file=order${id}_present.xyz
|
---|
| 23 | # normal
|
---|
| 24 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 25 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 26 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order -${i} -r], [], [ignore], [ignore])
|
---|
| 27 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/id${id}_present.xyz])
|
---|
| 28 | ((i+=1))
|
---|
| 29 | done
|
---|
| 30 | AT_CLEANUP
|
---|
| 31 |
|
---|
| 32 |
|
---|
| 33 | AT_SETUP([Unselection - atom with specific order with Undo])
|
---|
| 34 | AT_KEYWORDS([unselection order atom unselect-atom-by-order undo])
|
---|
| 35 | # go through all possible orders (0-7) and remove others
|
---|
| 36 | i=1
|
---|
| 37 | while test $i -le 8; do
|
---|
| 38 | let id=$i-1
|
---|
| 39 | file=order${id}_present.xyz
|
---|
| 40 | # undo
|
---|
| 41 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 42 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 43 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order ${i} --undo -r], [], [ignore], [ignore])
|
---|
| 44 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/empty.xyz])
|
---|
| 45 | ((i+=1))
|
---|
| 46 | done
|
---|
| 47 | # go reverse through all possible orders (0-7) and remove others
|
---|
| 48 | i=1
|
---|
| 49 | while test $i -le 8; do
|
---|
| 50 | let id=8-$i
|
---|
| 51 | file=order${id}_present.xyz
|
---|
| 52 | # undo
|
---|
| 53 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 54 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 55 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order -${i} --undo -r], [], [ignore], [ignore])
|
---|
| 56 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/empty.xyz])
|
---|
| 57 | ((i+=1))
|
---|
| 58 | done
|
---|
| 59 | AT_CLEANUP
|
---|
| 60 |
|
---|
| 61 |
|
---|
| 62 | AT_SETUP([Unselection - atom with specific order with Redo])
|
---|
| 63 | AT_KEYWORDS([unselection order atom unselect-atom-by-order redo])
|
---|
| 64 | # go through all possible orders (0-7) and remove others
|
---|
| 65 | i=1
|
---|
| 66 | while test $i -le 8; do
|
---|
| 67 | let id=$i-1
|
---|
| 68 | file=order${id}_present.xyz
|
---|
| 69 | # redo
|
---|
| 70 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 71 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 72 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order ${i} --undo --redo -r], [], [ignore], [ignore])
|
---|
| 73 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/id${id}_present.xyz])
|
---|
| 74 | ((i+=1))
|
---|
| 75 | done
|
---|
| 76 | # go reverse through all possible orders (0-7) and remove others
|
---|
| 77 | i=1
|
---|
| 78 | while test $i -le 8; do
|
---|
| 79 | let id=8-$i
|
---|
| 80 | file=order${id}_present.xyz
|
---|
| 81 | # redo
|
---|
| 82 | AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/pre/test.xyz $file])
|
---|
| 83 | AT_CHECK([chmod u+w $file], 0)
|
---|
| 84 | AT_CHECK([../../molecuilder -i $file -v 3 --select-all-atoms --unselect-atom-by-order -${i} --undo --redo -r], [], [ignore], [ignore])
|
---|
| 85 | AT_CHECK([diff -I '.*Created by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Selection/Atoms/AtomByOrder/post/id${id}_present.xyz])
|
---|
| 86 | ((i+=1))
|
---|
| 87 | done
|
---|
| 88 | AT_CLEANUP
|
---|