Ignore:
Timestamp:
Feb 25, 2010, 4:43:02 PM (16 years ago)
Author:
Tillmann Crueger <crueger@…>
Children:
3db67e
Parents:
2e6496
Message:

Made the world solely responsible for creating and erasing molecules.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • molecuilder/src/unittests/AnalysisCorrelationToSurfaceUnitTest.cpp

    r2e6496 r8d9d38  
    5656
    5757  // construct periodentafel
    58   tafel = new periodentafel;
     58  tafel = World::get()->getPeriode();
    5959  tafel->AddElement(hydrogen);
    6060  tafel->AddElement(carbon);
    6161
    6262  // construct molecule (tetraeder of hydrogens) base
    63   TestMolecule = new molecule(tafel);
     63  TestMolecule = World::get()->createMolecule();
    6464  Walker = World::get()->createAtom();
    6565  Walker->type = hydrogen;
     
    8282  CPPUNIT_ASSERT_EQUAL( TestMolecule->AtomCount, 4 );
    8383
    84   TestList = new MoleculeListClass;
     84  TestList = World::get()->getMolecules();
    8585  TestMolecule->ActiveFlag = true;
    8686  TestList->insert(TestMolecule);
     
    127127    delete(binmap);
    128128
    129   // remove
    130   delete(TestList);
    131129  delete(Surface);
    132130  // note that all the atoms are cleaned by TestMolecule
    133131  delete(LC);
    134   delete(tafel);
    135   // note that element is cleaned by periodentafel
     132  World::destroy();
    136133};
    137134
Note: See TracChangeset for help on using the changeset viewer.