From d6e99a696aa582b81018078b68f6600c8030d643 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Tue, 7 Nov 2023 02:51:42 +0000 Subject: WIP typedefing all the things - headers --- test/test-assetFactory.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test/test-assetFactory.cpp') diff --git a/test/test-assetFactory.cpp b/test/test-assetFactory.cpp index 145481e..177ab6a 100644 --- a/test/test-assetFactory.cpp +++ b/test/test-assetFactory.cpp @@ -183,14 +183,15 @@ BOOST_AUTO_TEST_CASE(texturePacker_many, *boost::unit_test::timeout(5)) { std::vector images(256); std::fill(images.begin(), images.end(), TexturePacker::Image {32, 32}); - const auto totalSize = std::accumulate(images.begin(), images.end(), 0U, [](auto t, const auto & i) { + const auto totalSize = std::accumulate(images.begin(), images.end(), 0, [](auto t, const auto & i) { return t + TexturePacker::area(i); }); TexturePacker tp {images}; BOOST_CHECK_EQUAL(TexturePacker::Size(32, 32), tp.minSize()); const auto result = tp.pack(); BOOST_CHECK_EQUAL(result.first.size(), images.size()); - BOOST_CHECK_GE(TexturePacker::area(result.second), TexturePacker::area(images.front()) * images.size()); + BOOST_CHECK_GE(TexturePacker::area(result.second), + TexturePacker::area(images.front()) * static_cast(images.size())); BOOST_CHECK_EQUAL(totalSize, TexturePacker::area(result.second)); } -- cgit v1.2.3