Commit 0014b8bd authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Port foreach

parent 798e2692
Pipeline #82410 passed with stage
in 8 minutes and 29 seconds
......@@ -111,7 +111,8 @@ void FilterActionTest::testMassModifyItems()
fjob->fetchScope().fetchAllAttributes();
AKVERIFYEXEC(fjob);
QCOMPARE(fjob->items().count(), 10);
foreach (const Item &item, fjob->items()) {
const auto fJobItems{fjob->items()};
for (const Item &item : fJobItems) {
QVERIFY(item.hasAttribute<TestAttribute>());
const QByteArray data = item.attribute<TestAttribute>()->data;
if (data == unacceptable) {
......@@ -145,7 +146,8 @@ void FilterActionTest::testMassModifyCollection()
fjob->fetchScope().fetchAllAttributes();
AKVERIFYEXEC(fjob);
QCOMPARE(fjob->items().count(), 10);
foreach (const Item &item, fjob->items()) {
const auto fjobItems{fjob->items()};
for (const Item &item : fjobItems) {
QVERIFY(item.hasAttribute<TestAttribute>());
const QByteArray data = item.attribute<TestAttribute>()->data;
if (data == unacceptable) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment