Changeset a9b2a0a for molecuilder/src/unittests
- Timestamp:
- Oct 27, 2009, 4:11:22 PM (16 years ago)
- Children:
- 069034
- Parents:
- 55a71b
- Location:
- molecuilder/src/unittests
- Files:
-
- 3 edited
-
ActOnAllUnitTest.cpp (modified) (2 diffs)
-
AnalysisCorrelationToPointUnitTest.cpp (modified) (1 diff)
-
AnalysisCorrelationToSurfaceUnitTest.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
molecuilder/src/unittests/ActOnAllUnitTest.cpp
r55a71b ra9b2a0a 62 62 63 63 // scaling by value 64 VL.ActOnAll( (void (Vector::*)( double)) &Vector::Scale, 2. );64 VL.ActOnAll( (void (Vector::*)(const double)) &Vector::Scale, 2. ); 65 65 CPPUNIT_ASSERT_EQUAL( VL == Ref , false ); 66 66 67 VL.ActOnAll( (void (Vector::*)( double)) &Vector::Scale, 0.5 );67 VL.ActOnAll( (void (Vector::*)(const double)) &Vector::Scale, 0.5 ); 68 68 CPPUNIT_ASSERT_EQUAL( VL == Ref , true ); 69 69 70 70 // scaling by ref 71 VL.ActOnAll( (void (Vector::*)( double *)) &Vector::Scale,&factor );71 VL.ActOnAll( (void (Vector::*)(const double * const)) &Vector::Scale, (const double * const)&factor ); 72 72 CPPUNIT_ASSERT_EQUAL( VL == Ref , false ); 73 73 74 VL.ActOnAll( (void (Vector::*)( double *)) &Vector::Scale,&inverse );74 VL.ActOnAll( (void (Vector::*)(const double * const)) &Vector::Scale, (const double * const)&inverse ); 75 75 CPPUNIT_ASSERT_EQUAL( VL == Ref , true ); 76 76 … … 82 82 inverses[i] = 1./factors[i]; 83 83 } 84 VL.ActOnAll( (void (Vector::*)( double **)) &Vector::Scale,&factors );84 VL.ActOnAll( (void (Vector::*)(const double ** const)) &Vector::Scale, (const double ** const)&factors ); 85 85 CPPUNIT_ASSERT_EQUAL( VL == Ref , false ); 86 86 87 VL.ActOnAll( (void (Vector::*)( double **)) &Vector::Scale,&inverses );87 VL.ActOnAll( (void (Vector::*)(const double ** const)) &Vector::Scale, (const double ** const)&inverses ); 88 88 CPPUNIT_ASSERT_EQUAL( VL == Ref , true ); 89 89 }; -
molecuilder/src/unittests/AnalysisCorrelationToPointUnitTest.cpp
r55a71b ra9b2a0a 77 77 78 78 // init maps 79 pointmap = CorrelationToPoint( (ofstream *)&cout, TestMolecule, hydrogen,point );79 pointmap = CorrelationToPoint( (ofstream *)&cout, (const molecule * const)TestMolecule, (const element * const)hydrogen, (const Vector *)point ); 80 80 binmap = NULL; 81 81 -
molecuilder/src/unittests/AnalysisCorrelationToSurfaceUnitTest.cpp
r55a71b ra9b2a0a 81 81 // init tesselation and linked cell 82 82 Surface = new Tesselation; 83 TestMolecule->TesselStruct = Surface; 84 FindNonConvexBorder((ofstream *)&cerr, TestMolecule, LC, 2.5, NULL); 83 FindNonConvexBorder((ofstream *)&cerr, TestMolecule, Surface, (const LinkedCell *&)LC, 2.5, NULL); 85 84 LC = new LinkedCell(TestMolecule, 5.); 86 85 CPPUNIT_ASSERT_EQUAL( (size_t)4, Surface->PointsOnBoundary.size() ); … … 123 122 // remove 124 123 delete(TestMolecule); 125 // note that Surface and all the atoms are cleaned by TestMolecule 124 delete(Surface); 125 // note that all the atoms are cleaned by TestMolecule 126 126 delete(LC); 127 127 delete(tafel);
Note:
See TracChangeset
for help on using the changeset viewer.
