Changeset 57f5cf for src/unittests/AnalysisCorrelationToSurfaceUnitTest.cpp
- Timestamp:
- Mar 4, 2010, 9:49:45 AM (16 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:
- ab4b55
- Parents:
- 6bc51d (diff), 88d586 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/unittests/AnalysisCorrelationToSurfaceUnitTest.cpp
r6bc51d r57f5cf 17 17 #include "AnalysisCorrelationToSurfaceUnitTest.hpp" 18 18 19 #include "World.hpp" 19 20 #include "atom.hpp" 20 21 #include "boundary.hpp" … … 60 61 61 62 // construct periodentafel 62 tafel = new periodentafel;63 tafel = World::get()->getPeriode(); 63 64 tafel->AddElement(hydrogen); 64 65 tafel->AddElement(carbon); 65 66 66 67 // construct molecule (tetraeder of hydrogens) base 67 TestMolecule = new molecule(tafel);68 Walker = new atom();68 TestMolecule = World::get()->createMolecule(); 69 Walker = World::get()->createAtom(); 69 70 Walker->type = hydrogen; 70 71 Walker->node->Init(1., 0., 1. ); 71 72 TestMolecule->AddAtom(Walker); 72 Walker = new atom();73 Walker = World::get()->createAtom(); 73 74 Walker->type = hydrogen; 74 75 Walker->node->Init(0., 1., 1. ); 75 76 TestMolecule->AddAtom(Walker); 76 Walker = new atom();77 Walker = World::get()->createAtom(); 77 78 Walker->type = hydrogen; 78 79 Walker->node->Init(1., 1., 0. ); 79 80 TestMolecule->AddAtom(Walker); 80 Walker = new atom();81 Walker = World::get()->createAtom(); 81 82 Walker->type = hydrogen; 82 83 Walker->node->Init(0., 0., 0. ); … … 86 87 CPPUNIT_ASSERT_EQUAL( TestMolecule->AtomCount, 4 ); 87 88 88 TestList = new MoleculeListClass;89 TestList = World::get()->getMolecules(); 89 90 TestMolecule->ActiveFlag = true; 90 91 TestList->insert(TestMolecule); … … 99 100 100 101 // add outer atoms 101 Walker = new atom();102 Walker = World::get()->createAtom(); 102 103 Walker->type = carbon; 103 104 Walker->node->Init(4., 0., 4. ); 104 105 TestMolecule->AddAtom(Walker); 105 Walker = new atom();106 Walker = World::get()->createAtom(); 106 107 Walker->type = carbon; 107 108 Walker->node->Init(0., 4., 4. ); 108 109 TestMolecule->AddAtom(Walker); 109 Walker = new atom();110 Walker = World::get()->createAtom(); 110 111 Walker->type = carbon; 111 112 Walker->node->Init(4., 4., 0. ); 112 113 TestMolecule->AddAtom(Walker); 113 114 // add inner atoms 114 Walker = new atom();115 Walker = World::get()->createAtom(); 115 116 Walker->type = carbon; 116 117 Walker->node->Init(0.5, 0.5, 0.5 ); … … 131 132 delete(binmap); 132 133 133 // remove134 delete(TestList);135 134 delete(Surface); 136 135 // note that all the atoms are cleaned by TestMolecule 137 136 delete(LC); 138 delete(tafel);139 // note that element is cleaned by periodentafel140 137 World::destroy(); 141 138 MemoryUsageObserver::purgeInstance();
Note:
See TracChangeset
for help on using the changeset viewer.
