summaryrefslogtreecommitdiff
path: root/test/libapt/srvrecs_test.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2017-03-14 11:35:41 +0100
committerDavid Kalnischkies <david@kalnischkies.de>2017-06-26 23:31:15 +0200
commitf78fb67f4b6a5673e497ba1aeb19568581173909 (patch)
treee4c25d36164ad232c04f4ab92256db593574c4da /test/libapt/srvrecs_test.cc
parente1d727654c49567f134ea74acee7ec57e7940069 (diff)
Refactor to avoid loop/dangling gcc warnings
Gbp-Dch: Ignore
Diffstat (limited to 'test/libapt/srvrecs_test.cc')
-rw-r--r--test/libapt/srvrecs_test.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/libapt/srvrecs_test.cc b/test/libapt/srvrecs_test.cc
index 5253b1c34..4fcc96dae 100644
--- a/test/libapt/srvrecs_test.cc
+++ b/test/libapt/srvrecs_test.cc
@@ -77,7 +77,9 @@ TEST(SrvRecTest,Randomness)
EXPECT_TRUE(std::all_of(first_pull.begin(), first_pull.end(), [](SrvRec const &R) { return R.priority == 20; }));
EXPECT_TRUE(std::all_of(second_pull.begin(), second_pull.end(), [](SrvRec const &R) { return R.priority == 20; }));
if (startingClock != -1 && startingClock != clock())
+ {
EXPECT_FALSE(std::equal(first_pull.begin(), first_pull.end(), second_pull.begin()));
+ }
EXPECT_TRUE(std::all_of(base2.begin(), base2.end(), [](SrvRec const &R) { return R.priority == 30; }));
}