- Timestamp:
- May 27, 2010, 10:46:54 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:
- 1024cb
- Parents:
- 8f215d (diff), 05a97c (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
r8f215d ra7b761b 26 26 #include "tesselation.hpp" 27 27 #include "World.hpp" 28 #include "Helpers/Assert.hpp" 28 29 29 30 #include "Helpers/Assert.hpp" … … 40 41 void AnalysisCorrelationToSurfaceUnitTest::setUp() 41 42 { 42 //ASSERT_DO(Assert::Throw);43 ASSERT_DO(Assert::Throw); 43 44 44 45 atom *Walker = NULL; … … 71 72 // construct molecule (tetraeder of hydrogens) base 72 73 TestSurfaceMolecule = World::getInstance().createMolecule(); 74 73 75 Walker = World::getInstance().createAtom(); 74 76 Walker->type = hydrogen; 75 77 *Walker->node = Vector(1., 0., 1. ); 76 77 TestSurfaceMolecule->AddAtom(Walker); 78 TestSurfaceMolecule->AddAtom(Walker); 79 78 80 Walker = World::getInstance().createAtom(); 79 81 Walker->type = hydrogen; 80 82 *Walker->node = Vector(0., 1., 1. ); 81 83 TestSurfaceMolecule->AddAtom(Walker); 84 82 85 Walker = World::getInstance().createAtom(); 83 86 Walker->type = hydrogen; 84 87 *Walker->node = Vector(1., 1., 0. ); 85 88 TestSurfaceMolecule->AddAtom(Walker); 89 86 90 Walker = World::getInstance().createAtom(); 87 91 Walker->type = hydrogen; … … 90 94 91 95 // check that TestMolecule was correctly constructed 92 CPPUNIT_ASSERT_EQUAL( TestSurfaceMolecule-> AtomCount, 4 );96 CPPUNIT_ASSERT_EQUAL( TestSurfaceMolecule->getAtomCount(), 4 ); 93 97 94 98 TestList = World::getInstance().getMolecules(); … … 107 111 *Walker->node = Vector(4., 0., 4. ); 108 112 TestSurfaceMolecule->AddAtom(Walker); 113 109 114 Walker = World::getInstance().createAtom(); 110 115 Walker->type = carbon; 111 116 *Walker->node = Vector(0., 4., 4. ); 112 117 TestSurfaceMolecule->AddAtom(Walker); 118 113 119 Walker = World::getInstance().createAtom(); 114 120 Walker->type = carbon; 115 121 *Walker->node = Vector(4., 4., 0. ); 116 122 TestSurfaceMolecule->AddAtom(Walker); 123 117 124 // add inner atoms 118 125 Walker = World::getInstance().createAtom(); … … 120 127 *Walker->node = Vector(0.5, 0.5, 0.5 ); 121 128 TestSurfaceMolecule->AddAtom(Walker); 129 122 130 TestSurfaceMolecule->ActiveFlag = true; 123 131 TestList->insert(TestSurfaceMolecule); … … 150 158 void AnalysisCorrelationToSurfaceUnitTest::SurfaceTest() 151 159 { 152 CPPUNIT_ASSERT_EQUAL( 4, TestSurfaceMolecule-> AtomCount);160 CPPUNIT_ASSERT_EQUAL( 4, TestSurfaceMolecule->getAtomCount() ); 153 161 CPPUNIT_ASSERT_EQUAL( (size_t)2, TestList->ListOfMolecules.size() ); 154 162 CPPUNIT_ASSERT_EQUAL( (size_t)4, Surface->PointsOnBoundary.size() );
Note:
See TracChangeset
for help on using the changeset viewer.
