/[escript]/trunk/escript/test/DataLazyTestCase.cpp
ViewVC logotype

Diff of /trunk/escript/test/DataLazyTestCase.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2166 by jfenwick, Mon Nov 24 00:45:48 2008 UTC revision 2167 by jfenwick, Tue Dec 16 23:31:05 2008 UTC
# Line 335  void DataLazyTestCase::testBuffers() Line 335  void DataLazyTestCase::testBuffers()
335    DataAbstract_ptr p2=(new DataLazy(p,SIN))->getPtr();    DataAbstract_ptr p2=(new DataLazy(p,SIN))->getPtr();
336    DataAbstract_ptr p3=(new DataLazy(p2,COS))->getPtr();    DataAbstract_ptr p3=(new DataLazy(p2,COS))->getPtr();
337    DataAbstract_ptr p4=(new DataLazy(p3,getLazy(shape),ADD))->getPtr();    DataAbstract_ptr p4=(new DataLazy(p3,getLazy(shape),ADD))->getPtr();
338    assert(dynamic_pointer_cast<DataLazy>(p4)->getBuffsRequired()==2);    assert(dynamic_pointer_cast<DataLazy>(p4)->getBuffsRequired()==4);
339    DataAbstract_ptr p5=(new DataLazy(p2,p4,ADD))->getPtr();    DataAbstract_ptr p5=(new DataLazy(p2,p4,ADD))->getPtr();
340    assert(dynamic_pointer_cast<DataLazy>(p5)->getBuffsRequired()==3);    assert(dynamic_pointer_cast<DataLazy>(p5)->getBuffsRequired()==6);
341    DataAbstract_ptr p6=(new DataLazy(p5,TRANS,0))->getPtr();    DataAbstract_ptr p6=(new DataLazy(p5,TRANS,0))->getPtr();
342    assert(dynamic_pointer_cast<DataLazy>(p6)->getBuffsRequired()==4);    assert(dynamic_pointer_cast<DataLazy>(p6)->getBuffsRequired()==7);
343    DataAbstract_ptr p7=(new DataLazy(p6,p6,PROD,0,0))->getPtr();    DataAbstract_ptr p7=(new DataLazy(p6,p6,PROD,0,0))->getPtr();
344    assert(dynamic_pointer_cast<DataLazy>(p7)->getBuffsRequired()==6);    assert(dynamic_pointer_cast<DataLazy>(p7)->getBuffsRequired()==9);
345    DataAbstract_ptr p8=(new DataLazy(p7,TRACE,0))->getPtr();    DataAbstract_ptr p8=(new DataLazy(p7,TRACE,0))->getPtr();
346    assert(dynamic_pointer_cast<DataLazy>(p8)->getBuffsRequired()==7);    assert(dynamic_pointer_cast<DataLazy>(p8)->getBuffsRequired()==10);
347  }  }
348    
349    

Legend:
Removed from v.2166  
changed lines
  Added in v.2167

  ViewVC Help
Powered by ViewVC 1.1.26