Changeset 88afc9
- Timestamp:
- Feb 13, 2015, 9:18:04 AM (11 years ago)
- Branches:
- Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, Candidate_v1.7.0, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
- Children:
- b9b49e
- Parents:
- 2fcef3
- git-author:
- Frederik Heber <heber@…> (01/29/15 00:25:11)
- git-committer:
- Frederik Heber <heber@…> (02/13/15 09:18:04)
- Files:
-
- 8 added
- 9 edited
-
doc/userguide/userguide.xml (modified) (2 diffs)
-
src/Actions/BondAction/BondAddAction.cpp (modified) (3 diffs)
-
src/Actions/BondAction/BondAddAction.def (modified) (3 diffs)
-
src/Actions/BondAction/BondRemoveAction.cpp (modified) (3 diffs)
-
src/Actions/BondAction/BondRemoveAction.def (modified) (3 diffs)
-
tests/regression/Bond/Add/post/test_multiple.pdb (added)
-
tests/regression/Bond/Add/pre/test_multiple.pdb (added)
-
tests/regression/Bond/Add/testsuite-bond-add.at (modified) (1 diff)
-
tests/regression/Bond/Add/testsuite-bond-add_multiple.at (added)
-
tests/regression/Bond/Remove/post/test_multiple.pdb (added)
-
tests/regression/Bond/Remove/post/test_multiple_undo.pdb (added)
-
tests/regression/Bond/Remove/pre/test_multiple.pdb (added)
-
tests/regression/Bond/Remove/pre/test_multiple_undo.pdb (added)
-
tests/regression/Bond/Remove/testsuite-bond-remove.at (modified) (1 diff)
-
tests/regression/Bond/Remove/testsuite-bond-remove_multiple.at (added)
-
tests/regression/Bond/testsuite-bond.at (modified) (1 diff)
-
tests/regression/Makefile.am (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
doc/userguide/userguide.xml
r2fcef3 r88afc9 1150 1150 </section> 1151 1151 1152 <section xml:id='bond.add -bond'>1153 <title xml:id='bond.add -bond.title'>Adding a bond manually</title>1152 <section xml:id='bond.adds-bond'> 1153 <title xml:id='bond.adds-bond.title'>Adding a bond manually</title> 1154 1154 1155 1155 <para>When the automatically created adjacency or bond graph 1156 1156 contains faulty bonds or lacks some, you can add them manually. 1157 First, you must have selected two atoms.</para> 1158 1159 <programlisting>... --add-bond</programlisting> 1160 </section> 1161 1162 <section xml:id='bond.remove-bond'> 1163 <title xml:id='bond.remove-bond.title'>Removing a bond manually 1157 </para> 1158 1159 <programlisting>... --add-bonds</programlisting> 1160 1161 <para>If two atoms are selected, the single bond in between, if not 1162 present, is added. If more than two atoms are selected, than the 1163 bond between any pair of these is added.</para> 1164 <note><para>This is especially useful in conjunction with the 1165 fragmentation scheme. If you want to know the contribution from 1166 certain fragments whose subgraph is not connected you can simply 1167 make the associated subset of atoms connected by selecting all 1168 bonds and adding the bonds.</para> 1169 </note> 1170 </section> 1171 1172 <section xml:id='bond.remove-bonds'> 1173 <title xml:id='bond.remove-bonds.title'>Removing a bond manually 1164 1174 </title> 1165 1175 … … 1167 1177 bond.</para> 1168 1178 1169 <programlisting>... --remove-bond</programlisting> 1179 <programlisting>... --remove-bonds</programlisting> 1180 1181 <para>Similarly, if more than two atoms are selected, then all bonds 1182 found between any pair of these is removed.</para> 1170 1183 </section> 1171 1184 -
src/Actions/BondAction/BondAddAction.cpp
r2fcef3 r88afc9 57 57 ActionState::ptr BondAddAction::performCall() { 58 58 // check preconditions 59 if (World::getInstance().countSelectedAtoms() != 2) { 60 STATUS("Exactly two atoms must be selected for BondAction Add."); 59 World& world = World::getInstance(); 60 if (world.countSelectedAtoms() <= 1) { 61 STATUS("There must be at least two atoms selected for BondAction Add."); 61 62 return Action::failure; 62 63 } 63 const std::vector<atom *> selected_atoms = World::getInstance().getSelectedAtoms(); 64 if (selected_atoms[0]->IsBondedTo(WorldTime::getTime(), selected_atoms[1])) { 65 STATUS("There already is a bond in between the two selected atoms."); 64 65 bondPairIds_t bondPairIds; 66 for (World::AtomSelectionConstIterator firstiter = world.beginAtomSelection(); 67 firstiter != world.endAtomSelection(); ++firstiter) { 68 for (World::AtomSelectionConstIterator seconditer = firstiter; 69 seconditer != world.endAtomSelection(); ++seconditer) { 70 if (firstiter == seconditer) 71 continue; 72 if (!(firstiter->second)->IsBondedTo(WorldTime::getTime(), seconditer->second)) 73 bondPairIds.push_back( 74 std::make_pair((firstiter->second)->getId(), (seconditer->second)->getId())); 75 } 76 } 77 if (bondPairIds.empty()) { 78 STATUS("All bonds are already present."); 66 79 return Action::failure; 67 80 } 68 81 69 82 // create undo 70 BondAddState *UndoState = new BondAddState( selected_atoms[0]->getId(), selected_atoms[1]->getId(), params);83 BondAddState *UndoState = new BondAddState(bondPairIds, params); 71 84 72 85 // execute action 73 selected_atoms[0]->addBond(WorldTime::getTime(), selected_atoms[1]); 74 ASSERT( selected_atoms[0]->IsBondedTo(WorldTime::getTime(), selected_atoms[1]), 86 for (bondPairIds_t::const_iterator iter = bondPairIds.begin(); 87 iter != bondPairIds.end(); ++iter) { 88 atom *firstatom = world.getAtom(AtomById(iter->first)); 89 atom *secondatom = world.getAtom(AtomById(iter->second)); 90 ASSERT((firstatom != NULL) && (secondatom != NULL), 91 "BondAddAction::performCall() - at least one of the ids " 92 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 93 firstatom->addBond(WorldTime::getTime(), secondatom); 94 ASSERT( firstatom->IsBondedTo(WorldTime::getTime(), secondatom), 75 95 "BondAddAction::performCall() - adding bond in between " 76 +toString(*selected_atoms[0])+" and "+toString(*selected_atoms[1])+" failed."); 96 +toString(*firstatom)+" and "+toString(*secondatom)+" failed."); 97 } 77 98 78 99 return ActionState::ptr(UndoState); … … 83 104 84 105 // check whether bond already existed 85 atom * const first = World::getInstance().getAtom(AtomById(state->firstId)); 86 atom * const second = World::getInstance().getAtom(AtomById(state->secondId)); 87 ASSERT((first != NULL) && (second != NULL), 88 "BondAddAction::performUndo() - at least one of the ids " 89 +toString(state->firstId)+" or "+toString(state->secondId)+" is not present."); 90 if (first->IsBondedTo(WorldTime::getTime(), second)) { 91 first->removeBond(WorldTime::getTime(), second); 92 } else { 93 ELOG(2, "There is no bond in between "+toString(state->firstId) 94 +" and "+toString(state->secondId)+"."); 106 World& world = World::getInstance(); 107 for (bondPairIds_t::const_iterator iter = state->bondPairIds.begin(); 108 iter != state->bondPairIds.end(); ++iter) { 109 atom *firstatom = world.getAtom(AtomById(iter->first)); 110 atom *secondatom = world.getAtom(AtomById(iter->second)); 111 ASSERT((firstatom != NULL) && (secondatom != NULL), 112 "BondAddAction::performCall() - at least one of the ids " 113 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 114 if (firstatom->IsBondedTo(WorldTime::getTime(), secondatom)) { 115 firstatom->removeBond(WorldTime::getTime(), secondatom); 116 } else { 117 ELOG(2, "There is no bond in between "+toString(iter->first) 118 +" and "+toString(iter->second)+"."); 119 } 95 120 } 96 121 … … 102 127 103 128 // check whether bond already existed 104 atom * const first = World::getInstance().getAtom(AtomById(state->firstId)); 105 atom * const second = World::getInstance().getAtom(AtomById(state->secondId)); 106 ASSERT((first != NULL) && (second != NULL), 107 "BondAddAction::performRedo() - at least one of the ids " 108 +toString(state->firstId)+" or "+toString(state->secondId)+" is not present."); 109 if (!first->IsBondedTo(WorldTime::getTime(), second)) { 110 first->addBond(WorldTime::getTime(), second); 111 } else { 112 ELOG(2, "There is already a bond in between "+toString(state->firstId) 113 +" and "+toString(state->secondId)+"."); 129 World& world = World::getInstance(); 130 for (bondPairIds_t::const_iterator iter = state->bondPairIds.begin(); 131 iter != state->bondPairIds.end(); ++iter) { 132 atom * const firstatom = world.getAtom(AtomById(iter->first)); 133 atom * const secondatom = world.getAtom(AtomById(iter->second)); 134 ASSERT((firstatom != NULL) && (secondatom != NULL), 135 "BondAddAction::performCall() - at least one of the ids " 136 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 137 if (!firstatom->IsBondedTo(WorldTime::getTime(), secondatom)) { 138 firstatom->addBond(WorldTime::getTime(), secondatom); 139 } else { 140 ELOG(2, "There is already a bond in between "+toString(iter->first) 141 +" and "+toString(iter->second)+"."); 142 } 114 143 } 115 144 -
src/Actions/BondAction/BondAddAction.def
r2fcef3 r88afc9 8 8 // all includes and forward declarations necessary for non-integral types below 9 9 #include "types.hpp" 10 #include <vector> 11 #include <utility> 12 13 typedef std::vector<std::pair<atomId_t,atomId_t> > bondPairIds_t; 10 14 11 15 // i.e. there is an integer with variable name Z that can be found in … … 20 24 #undef paramvalids 21 25 22 #define statetypes ( atomId_t)(atomId_t)23 #define statereferences ( firstId)(secondId)26 #define statetypes (bondPairIds_t) 27 #define statereferences (bondPairIds) 24 28 25 29 // some defines for all the names, you may use ACTION, STATE and PARAMS … … 28 32 #define MENUPOSITION 1 29 33 #define ACTIONNAME Add 30 #define TOKEN "add-bond "34 #define TOKEN "add-bonds" 31 35 32 36 // finally the information stored in the ActionTrait specialization 33 #define DESCRIPTION "add bond in between twoselected atoms"37 #define DESCRIPTION "add bonds in between any number of selected atoms" 34 38 #undef SHORTFORM -
src/Actions/BondAction/BondRemoveAction.cpp
r2fcef3 r88afc9 57 57 ActionState::ptr BondRemoveAction::performCall() { 58 58 // check preconditions 59 if (World::getInstance().countSelectedAtoms() != 2) { 60 STATUS("Exactly two atoms must be selected for BondAction Remove."); 59 World& world = World::getInstance(); 60 if (world.countSelectedAtoms() <= 1) { 61 STATUS("At least two atoms must be selected for BondAction Remove."); 61 62 return Action::failure; 62 63 } 63 const std::vector<atom *> selected_atoms = World::getInstance().getSelectedAtoms(); 64 if (!selected_atoms[0]->IsBondedTo(WorldTime::getTime(), selected_atoms[1])) { 65 STATUS("There is no bond in between the two selected atoms."); 64 65 bondPairIds_t bondPairIds; 66 for (World::AtomSelectionConstIterator firstiter = world.beginAtomSelection(); 67 firstiter != world.endAtomSelection(); ++firstiter) { 68 for (World::AtomSelectionConstIterator seconditer = firstiter; 69 seconditer != world.endAtomSelection(); ++seconditer) { 70 if (firstiter == seconditer) 71 continue; 72 if ((firstiter->second)->IsBondedTo(WorldTime::getTime(), seconditer->second)) 73 bondPairIds.push_back( 74 std::make_pair((firstiter->second)->getId(), (seconditer->second)->getId())); 75 } 76 } 77 if (bondPairIds.empty()) { 78 STATUS("No bonds are present."); 66 79 return Action::failure; 67 80 } 68 81 69 82 // create undo 70 BondRemoveState *UndoState = new BondRemoveState( selected_atoms[0]->getId(), selected_atoms[1]->getId(), params);83 BondRemoveState *UndoState = new BondRemoveState(bondPairIds, params); 71 84 72 85 // execute action 73 selected_atoms[0]->removeBond(WorldTime::getTime(), selected_atoms[1]); 74 ASSERT( !selected_atoms[0]->IsBondedTo(WorldTime::getTime(), selected_atoms[1]), 75 "BondRemoveAction::performCall() - removing bond in between " 76 +toString(*selected_atoms[0])+" and "+toString(*selected_atoms[1])+" failed."); 86 for (bondPairIds_t::const_iterator iter = bondPairIds.begin(); 87 iter != bondPairIds.end(); ++iter) { 88 atom *firstatom = world.getAtom(AtomById(iter->first)); 89 atom *secondatom = world.getAtom(AtomById(iter->second)); 90 ASSERT((firstatom != NULL) && (secondatom != NULL), 91 "BondAddAction::performCall() - at least one of the ids " 92 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 93 firstatom->removeBond(WorldTime::getTime(), secondatom); 94 ASSERT( !firstatom->IsBondedTo(WorldTime::getTime(), secondatom), 95 "BondAddAction::performCall() - adding bond in between " 96 +toString(*firstatom)+" and "+toString(*secondatom)+" failed."); 97 } 77 98 78 99 return ActionState::ptr(UndoState); … … 82 103 BondRemoveState *state = assert_cast<BondRemoveState*>(_state.get()); 83 104 84 // check whether bond already existed 85 atom * const first = World::getInstance().getAtom(AtomById(state->firstId)); 86 atom * const second = World::getInstance().getAtom(AtomById(state->secondId)); 87 ASSERT((first != NULL) && (second != NULL), 88 "BondRemoveAction::performUndo() - at least one of the ids " 89 +toString(state->firstId)+" or "+toString(state->secondId)+" is not present."); 90 if (!first->IsBondedTo(WorldTime::getTime(), second)) { 91 first->addBond(WorldTime::getTime(), second); 92 } else { 93 ELOG(2, "There is already a bond in between "+toString(state->firstId) 94 +" and "+toString(state->secondId)+"."); 105 World& world = World::getInstance(); 106 for (bondPairIds_t::const_iterator iter = state->bondPairIds.begin(); 107 iter != state->bondPairIds.end(); ++iter) { 108 atom * const firstatom = world.getAtom(AtomById(iter->first)); 109 atom * const secondatom = world.getAtom(AtomById(iter->second)); 110 ASSERT((firstatom != NULL) && (secondatom != NULL), 111 "BondAddAction::performCall() - at least one of the ids " 112 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 113 if (!firstatom->IsBondedTo(WorldTime::getTime(), secondatom)) { 114 firstatom->addBond(WorldTime::getTime(), secondatom); 115 } else { 116 ELOG(2, "There is already a bond in between "+toString(iter->first) 117 +" and "+toString(iter->second)+"."); 118 } 95 119 } 96 120 … … 101 125 BondRemoveState *state = assert_cast<BondRemoveState*>(_state.get()); 102 126 103 // check whether bond already existed 104 atom * const first = World::getInstance().getAtom(AtomById(state->firstId)); 105 atom * const second = World::getInstance().getAtom(AtomById(state->secondId)); 106 ASSERT((first != NULL) && (second != NULL), 107 "BondRemoveAction::performRedo() - at least one of the ids " 108 +toString(state->firstId)+" or "+toString(state->secondId)+" is not present."); 109 if (first->IsBondedTo(WorldTime::getTime(), second)) { 110 first->removeBond(WorldTime::getTime(), second); 111 } else { 112 ELOG(2, "There is no bond in between "+toString(state->firstId) 113 +" and "+toString(state->secondId)+"."); 127 World& world = World::getInstance(); 128 for (bondPairIds_t::const_iterator iter = state->bondPairIds.begin(); 129 iter != state->bondPairIds.end(); ++iter) { 130 atom *firstatom = world.getAtom(AtomById(iter->first)); 131 atom *secondatom = world.getAtom(AtomById(iter->second)); 132 ASSERT((firstatom != NULL) && (secondatom != NULL), 133 "BondAddAction::performCall() - at least one of the ids " 134 +toString(iter->first)+" or "+toString(iter->second)+" is not present."); 135 if (firstatom->IsBondedTo(WorldTime::getTime(), secondatom)) { 136 firstatom->removeBond(WorldTime::getTime(), secondatom); 137 } else { 138 ELOG(2, "There is no bond in between "+toString(iter->first) 139 +" and "+toString(iter->second)+"."); 140 } 114 141 } 115 142 -
src/Actions/BondAction/BondRemoveAction.def
r2fcef3 r88afc9 7 7 8 8 // all includes and forward declarations necessary for non-integral types below 9 #include "types.hpp" 10 #include <vector> 11 #include <utility> 12 13 typedef std::vector<std::pair<atomId_t,atomId_t> > bondPairIds_t; 9 14 10 15 // i.e. there is an integer with variable name Z that can be found in … … 19 24 #undef paramvalids 20 25 21 #define statetypes ( atomId_t)(atomId_t)22 #define statereferences ( firstId)(secondId)26 #define statetypes (bondPairIds_t) 27 #define statereferences (bondPairIds) 23 28 24 29 // some defines for all the names, you may use ACTION, STATE and PARAMS … … 27 32 #define MENUPOSITION 2 28 33 #define ACTIONNAME Remove 29 #define TOKEN "remove-bond "34 #define TOKEN "remove-bonds" 30 35 31 36 // finally the information stored in the ActionTrait specialization 32 #define DESCRIPTION "remove the bond in between twoselected atoms"37 #define DESCRIPTION "remove all bonds present between selected atoms" 33 38 #undef SHORTFORM -
tests/regression/Bond/Add/testsuite-bond-add.at
r2fcef3 r88afc9 19 19 20 20 AT_SETUP([Bond - adding bond]) 21 AT_KEYWORDS([bond add-bond ])21 AT_KEYWORDS([bond add-bonds]) 22 22 file=test.pdb 23 23 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Add/pre/$file $file], 0, [ignore], [ignore]) 24 24 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 25 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bond ], 0, [ignore], [ignore])26 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/post/ test.pdb], 0, [ignore], [ignore])25 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bonds], 0, [ignore], [ignore]) 26 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/post/$file], 0, [ignore], [ignore]) 27 27 AT_CLEANUP 28 28 29 29 30 30 AT_SETUP([Bond - adding bond with Undo]) 31 AT_KEYWORDS([bond add-bond undo])31 AT_KEYWORDS([bond add-bonds undo]) 32 32 file=test.pdb 33 33 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Add/pre/$file $file], 0, [ignore], [ignore]) 34 34 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 35 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bond --undo], 0, [ignore], [ignore])36 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/pre/ test.pdb], 0, [ignore], [ignore])35 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bonds --undo], 0, [ignore], [ignore]) 36 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/pre/$file], 0, [ignore], [ignore]) 37 37 AT_CLEANUP 38 38 39 39 40 40 AT_SETUP([Bond - adding bond with Redo]) 41 AT_KEYWORDS([bond add-bond redo])41 AT_KEYWORDS([bond add-bonds redo]) 42 42 file=test.pdb 43 43 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Add/pre/$file $file], 0, [ignore], [ignore]) 44 44 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 45 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bond --undo --redo], 0, [ignore], [ignore])46 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/post/ test.pdb], 0, [ignore], [ignore])45 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --add-bonds --undo --redo], 0, [ignore], [ignore]) 46 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Add/post/$file], 0, [ignore], [ignore]) 47 47 AT_CLEANUP -
tests/regression/Bond/Remove/testsuite-bond-remove.at
r2fcef3 r88afc9 19 19 20 20 AT_SETUP([Bond - removing bond]) 21 AT_KEYWORDS([bond remove-bond ])21 AT_KEYWORDS([bond remove-bonds]) 22 22 file=test.pdb 23 23 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Remove/pre/$file $file], 0, [ignore], [ignore]) 24 24 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 25 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bond ], 0, [ignore], [ignore])26 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/post/ test.pdb], 0, [ignore], [ignore])25 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bonds], 0, [ignore], [ignore]) 26 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/post/$file], 0, [ignore], [ignore]) 27 27 AT_CLEANUP 28 28 29 29 30 30 AT_SETUP([Bond - removing bond with Undo]) 31 AT_KEYWORDS([bond remove-bond undo])31 AT_KEYWORDS([bond remove-bonds undo]) 32 32 file=test.pdb 33 33 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Remove/pre/$file $file], 0, [ignore], [ignore]) 34 34 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 35 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bond --undo], 0, [ignore], [ignore])36 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/pre/ test.pdb], 0, [ignore], [ignore])35 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bonds --undo], 0, [ignore], [ignore]) 36 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/pre/$file], 0, [ignore], [ignore]) 37 37 AT_CLEANUP 38 38 39 39 40 40 AT_SETUP([Bond - removing bond with Redo]) 41 AT_KEYWORDS([bond remove-bond redo])41 AT_KEYWORDS([bond remove-bonds redo]) 42 42 file=test.pdb 43 43 AT_CHECK([cp -f ${abs_top_srcdir}/tests/regression/Bond/Remove/pre/$file $file], 0, [ignore], [ignore]) 44 44 AT_CHECK([chmod +w $file], 0, [ignore], [ignore]) 45 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bond --undo --redo], 0, [ignore], [ignore])46 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/post/ test.pdb], 0, [ignore], [ignore])45 AT_CHECK([../../molecuilder -i $file -o pdb --select-atom-by-id 0 1 --remove-bonds --undo --redo], 0, [ignore], [ignore]) 46 AT_CHECK([diff -I '.*reated by molecuilder.*' $file ${abs_top_srcdir}/tests/regression/Bond/Remove/post/$file], 0, [ignore], [ignore]) 47 47 AT_CLEANUP -
tests/regression/Bond/testsuite-bond.at
r2fcef3 r88afc9 20 20 # add bond 21 21 m4_include([Bond/Add/testsuite-bond-add.at]) 22 m4_include([Bond/Add/testsuite-bond-add_multiple.at]) 22 23 23 24 # remove bond 24 25 m4_include([Bond/Remove/testsuite-bond-remove.at]) 26 m4_include([Bond/Remove/testsuite-bond-remove_multiple.at]) -
tests/regression/Makefile.am
r2fcef3 r88afc9 46 46 $(srcdir)/Bond/testsuite-bond.at \ 47 47 $(srcdir)/Bond/Add/testsuite-bond-add.at \ 48 $(srcdir)/Bond/Add/testsuite-bond-add_multiple.at \ 48 49 $(srcdir)/Bond/Remove/testsuite-bond-remove.at \ 50 $(srcdir)/Bond/Remove/testsuite-bond-remove_multiple.at \ 49 51 $(srcdir)/Analysis/testsuite-analysis.at \ 50 52 $(srcdir)/Analysis/DipoleAngularCorrelation/testsuite-analysis-dipole-angular-correlation.at \
Note:
See TracChangeset
for help on using the changeset viewer.
