Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/unittests/vectorunittest.cpp

    r27ac00 r36166d  
    1515#include "defs.hpp"
    1616#include "log.hpp"
    17 #include "memoryusageobserver.hpp"
    1817#include "vector.hpp"
    1918#include "vector_ops.hpp"
     
    2120#include "Plane.hpp"
    2221#include "Exceptions/LinearDependenceException.hpp"
     22#include "Matrix.hpp"
    2323
    2424#ifdef HAVE_TESTRUNNER
     
    4949void VectorTest::tearDown()
    5050{
    51   MemoryUsageObserver::purgeInstance();
    5251  logger::purgeInstance();
    5352  errorLogger::purgeInstance();
     
    215214  CPPUNIT_ASSERT(testVector.ScalarProduct(three) < MYEPSILON);
    216215}
    217 
    218 
    219 /**
    220  * UnitTest for Vector::IsInParallelepiped().
    221  */
    222 void VectorTest::IsInParallelepipedTest()
    223 {
    224   double parallelepiped[NDIM*NDIM];
    225   parallelepiped[0] = 1;
    226   parallelepiped[1] = 0;
    227   parallelepiped[2] = 0;
    228   parallelepiped[3] = 0;
    229   parallelepiped[4] = 1;
    230   parallelepiped[5] = 0;
    231   parallelepiped[6] = 0;
    232   parallelepiped[7] = 0;
    233   parallelepiped[8] = 1;
    234 
    235   fixture = zero;
    236   CPPUNIT_ASSERT_EQUAL( false, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    237   fixture = Vector(2.5,2.5,2.5);
    238   CPPUNIT_ASSERT_EQUAL( true, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    239   fixture = Vector(1.,1.,1.);
    240   CPPUNIT_ASSERT_EQUAL( false, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    241   fixture = Vector(3.5,3.5,3.5);
    242   CPPUNIT_ASSERT_EQUAL( false, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    243   fixture = Vector(2.,2.,2.);
    244   CPPUNIT_ASSERT_EQUAL( true, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    245   fixture = Vector(2.,3.,2.);
    246   CPPUNIT_ASSERT_EQUAL( true, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    247   fixture = Vector(-2.,2.,-1.);
    248   CPPUNIT_ASSERT_EQUAL( false, fixture.IsInParallelepiped(Vector(2.,2.,2.), parallelepiped) );
    249 }
    250 
Note: See TracChangeset for help on using the changeset viewer.