mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-14 13:50:13 +00:00
TESTS: Remove unnecessary heap allocation
This commit is contained in:
parent
62825c5cf8
commit
9f465b4062
@ -127,14 +127,14 @@ class PtrTestSuite : public CxxTest::TestSuite {
|
|||||||
|
|
||||||
void test_deleter() {
|
void test_deleter() {
|
||||||
Deleter<int> myDeleter;
|
Deleter<int> myDeleter;
|
||||||
myDeleter.test = new bool(false);
|
bool test = false;
|
||||||
|
myDeleter.test = &test;
|
||||||
|
|
||||||
{
|
{
|
||||||
Common::SharedPtr<int> p(new int(1), myDeleter);
|
Common::SharedPtr<int> p(new int(1), myDeleter);
|
||||||
}
|
}
|
||||||
|
|
||||||
TS_ASSERT_EQUALS(*myDeleter.test, true);
|
TS_ASSERT_EQUALS(test, true);
|
||||||
delete myDeleter.test;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void test_compare() {
|
void test_compare() {
|
||||||
|
Loading…
Reference in New Issue
Block a user