diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2016-06-02 21:11:47 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2016-06-02 21:11:47 +0200 |
commit | 558dd20585223baf1dfbe1bbe88e352334239ef5 (patch) | |
tree | 88aee920d6e5f3cace47de32bd723b3e189710b1 | |
parent | ab7ab9e52ab87963831f90ab25957d883878654d (diff) |
Fix test compilation on 64 bit.
-rw-r--r-- | test/imagecachetest.cc | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/test/imagecachetest.cc b/test/imagecachetest.cc index 2a5b6ed..9321cf0 100644 --- a/test/imagecachetest.cc +++ b/test/imagecachetest.cc @@ -62,35 +62,35 @@ public: void refCountTest() { TestableImageCache imageCache; - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 0u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 0u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(0u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(0u)); { auto image1{imageCache.getImage("foo")}; (void)image1; - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 1u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 0u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(1u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(0u)); auto image2 = imageCache.getImage("bar"); - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 1u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 1u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(1u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(1u)); auto image3 = imageCache.getImage("foo"); - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 2u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 1u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(2u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(1u)); { auto image4 = imageCache.getImage("foo"); - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 3u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 1u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(3u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(1u)); } - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 2u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 1u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(2u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(1u)); } - CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), 0u); - CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), 0u); + CPPUNIT_ASSERT_EQUAL(imageCache.count("foo"), std::size_t(0u)); + CPPUNIT_ASSERT_EQUAL(imageCache.count("bar"), std::size_t(0u)); } }; |