diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-02-20 18:32:46 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-02-20 18:32:46 +0300 |
commit | 6e2c26e53bda22a10994fe3940fddde7ea548089 (patch) | |
tree | c3746f4fb52f085fbbaaf7d4a92f4ea8cd825581 /src/resources | |
parent | cf772ab6f9fdfe1647b9b7b79aab685ebc831f31 (diff) | |
download | manaplus-6e2c26e53bda22a10994fe3940fddde7ea548089.tar.gz manaplus-6e2c26e53bda22a10994fe3940fddde7ea548089.tar.bz2 manaplus-6e2c26e53bda22a10994fe3940fddde7ea548089.tar.xz manaplus-6e2c26e53bda22a10994fe3940fddde7ea548089.zip |
Fix all left leaks in tests.
Diffstat (limited to 'src/resources')
-rw-r--r-- | src/resources/map/maplayer_unittest.cc | 4 | ||||
-rw-r--r-- | src/resources/resource.h | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/resources/map/maplayer_unittest.cc b/src/resources/map/maplayer_unittest.cc index 5d7f5c258..f2efd49a6 100644 --- a/src/resources/map/maplayer_unittest.cc +++ b/src/resources/map/maplayer_unittest.cc @@ -1992,6 +1992,7 @@ TEST_CASE("MapLayer drawSpecialLayer (specialLayer)") delete map; delete mock; + GraphicsManager::deleteRenderers(); delete2(logger); } @@ -2348,6 +2349,7 @@ TEST_CASE("MapLayer drawSpecialLayer (tempLayer)") delete map; delete mock; + GraphicsManager::deleteRenderers(); delete2(logger); } @@ -3231,5 +3233,7 @@ TEST_CASE("MapLayer drawFringe") delete img2; delete img3; delete mock; + delete2(theme); + GraphicsManager::deleteRenderers(); delete2(logger); } diff --git a/src/resources/resource.h b/src/resources/resource.h index f90890e19..e9f7e0531 100644 --- a/src/resources/resource.h +++ b/src/resources/resource.h @@ -110,7 +110,9 @@ class Resource notfinal : public MemoryCounter { mDumped = n; } #endif // DEBUG_DUMP_LEAKS +#ifndef UNITTESTS protected: +#endif // UNITTESTS /** * Destructor. */ |