diff options
author | Arkadiy Illarionov <qarkai@gmail.com> | 2018-10-24 00:49:27 +0300 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-10-24 14:45:19 +0200 |
commit | 86192438d16ec160d6b59d08735e770ee05ac113 (patch) | |
tree | 25dbb9dde6631d49b0ea8483c8f3018def3ddd0d /test/source/sheet/xdatapilottable2.cxx | |
parent | 6f50961e69406a17d6ec998956a6b33208b1001b (diff) |
Simplify containers iterations in test..tools
Use range-based loop or replace with STL functions.
Change-Id: If8fac9236a4696c8e56c0e81c60c429782581b96
Reviewed-on: https://gerrit.libreoffice.org/62262
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'test/source/sheet/xdatapilottable2.cxx')
-rw-r--r-- | test/source/sheet/xdatapilottable2.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/test/source/sheet/xdatapilottable2.cxx b/test/source/sheet/xdatapilottable2.cxx index d54a12f425bb..dc23c1045cb4 100644 --- a/test/source/sheet/xdatapilottable2.cxx +++ b/test/source/sheet/xdatapilottable2.cxx @@ -63,10 +63,9 @@ void XDataPilotTable2::testGetDrillDownData() buildDataFields(xDPTable); buildResultCells(xDPTable); - for (std::vector<table::CellAddress>::iterator itr = maResultCells.begin(); - itr != maResultCells.end(); ++itr) + for (const auto& rResultCell : maResultCells) { - sheet::DataPilotTablePositionData aPosData = xDPTable->getPositionData(*itr); + sheet::DataPilotTablePositionData aPosData = xDPTable->getPositionData(rResultCell); Any aTempAny = aPosData.PositionData; sheet::DataPilotTableResultData aResData; CPPUNIT_ASSERT(aTempAny >>= aResData); @@ -74,7 +73,7 @@ void XDataPilotTable2::testGetDrillDownData() sheet::DataResult aRes = aResData.Result; double nVal = aRes.Value; - Sequence< Sequence<Any> > aData = xDPTable->getDrillDownData(*itr); + Sequence< Sequence<Any> > aData = xDPTable->getDrillDownData(rResultCell); double sum = 0; if( aData.getLength() > 1 ) |