Skip to content
Snippets Groups Projects
Commit a362039a authored by Sam Yates's avatar Sam Yates
Browse files

Signed/unsigned comparison warning fix in unit test.

parent dd95b67c
No related branches found
No related tags found
No related merge requests found
...@@ -108,11 +108,11 @@ TEST(compartments, compartment_range) ...@@ -108,11 +108,11 @@ TEST(compartments, compartment_range)
{ {
nest::mc::compartment_range rng(10, 1.0, 2.0, 10.); nest::mc::compartment_range rng(10, 1.0, 2.0, 10.);
EXPECT_EQ((*rng.begin()).index, 0); EXPECT_EQ((*rng.begin()).index, 0u);
EXPECT_EQ((*rng.end()).index, 10); EXPECT_EQ((*rng.end()).index, 10u);
EXPECT_NE(rng.begin(), rng.end()); EXPECT_NE(rng.begin(), rng.end());
int count = 0; unsigned count = 0;
for(auto c : rng) { for(auto c : rng) {
EXPECT_EQ(c.index, count); EXPECT_EQ(c.index, count);
auto er = 1.0 + double(count)/10.; auto er = 1.0 + double(count)/10.;
...@@ -121,7 +121,7 @@ TEST(compartments, compartment_range) ...@@ -121,7 +121,7 @@ TEST(compartments, compartment_range)
EXPECT_EQ(c.length, 1.0); EXPECT_EQ(c.length, 1.0);
++count; ++count;
} }
EXPECT_EQ(count, 10); EXPECT_EQ(count, 10u);
} }
// test case of zero length range // test case of zero length range
......
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