Definition at line 45 of file testTableDataView.h. References IsValidTableDataViewTest(). 00045 { 00046 IsValidTableDataViewTest(view); 00047 for(int i=0; i < view->GetTotalRows(); i++) { 00048 BOOST_CHECK_EQUAL(view->GetSortedIntData("id", i), i); 00049 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("red", i), i/(double)view->GetTotalRows()); 00050 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("green", i), 1.0-view->GetSortedNormalizedData("red", i)); 00051 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("blue", i), i%10 / 10.0); 00052 } 00053 view->SetSortColumn("red"); 00054 for(int i=0; i < view->GetTotalRows(); i++) { 00055 BOOST_CHECK_EQUAL(view->GetSortedIntData("id", view->GetTotalRows()-1-i), i); 00056 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("red", view->GetTotalRows()-1-i), i/(double)view->GetTotalRows()); 00057 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("green", view->GetTotalRows()-1-i), 1.0-view->GetSortedNormalizedData("red", view->GetTotalRows()-1-i)); 00058 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("blue", view->GetTotalRows()-1-i), i%10 / 10.0); 00059 } 00060 view->SetSortColumn("red", false); 00061 for(int i=0; i < view->GetTotalRows(); i++) { 00062 BOOST_CHECK_EQUAL(view->GetSortedIntData("id", i), i); 00063 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("red", i), i/(double)view->GetTotalRows()); 00064 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("green", i), 1.0-view->GetSortedNormalizedData("red", i)); 00065 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("blue", i), i%10 / 10.0); 00066 } 00067 view->SetSortColumn("blue", false); 00068 for(int i=0; i < view->GetTotalRows(); i++) { 00069 BOOST_CHECK_EQUAL(view->GetSortedNormalizedData("green", i), 1.0-view->GetSortedNormalizedData("red", i)); 00070 } 00071 }
Here is the call graph for this function:
|