diff --git a/test/auto/domain/tst_domain.cpp b/test/auto/domain/tst_domain.cpp index ee5dacc..c1ec2eb 100644 --- a/test/auto/domain/tst_domain.cpp +++ b/test/auto/domain/tst_domain.cpp @@ -597,7 +597,6 @@ void tst_Domain::zoom() TRY_COMPARE(spy0.count(), 6); TRY_COMPARE(spy1.count(), 6); TRY_COMPARE(spy2.count(), 6); - } void tst_Domain::move_data() @@ -633,8 +632,8 @@ void tst_Domain::move() QCOMPARE(domain == result, true); TRY_COMPARE(spy0.count(), 1); - TRY_COMPARE(spy1.count(), dx!=0?1:0); - TRY_COMPARE(spy2.count(), dy!=0?1:0); + TRY_COMPARE(spy1.count(), (dx != 0 ? 1 : 0)); + TRY_COMPARE(spy2.count(), (dy != 0 ? 1 : 0)); } void tst_Domain::handleAxisXChanged_data() diff --git a/test/auto/inc/tst_definitions.h b/test/auto/inc/tst_definitions.h index bac89c4..f30e9bb 100644 --- a/test/auto/inc/tst_definitions.h +++ b/test/auto/inc/tst_definitions.h @@ -29,7 +29,7 @@ const int waitStep(30); \ /* always wait before comparing to catch possible extra signals */ \ QTest::qWait(waitStep); \ - for (int time(0); actual != expected && time < timeout; time += waitStep) \ + for (int time(0); (actual != expected) && (time < timeout); time += waitStep) \ QTest::qWait(waitStep); \ QCOMPARE(actual, expected); \ } while (0); \