MCPcopy Create free account
hub / github.com/KDE/kdevelop / testBehaviorOnDestruction

Method testBehaviorOnDestruction

kdevplatform/util/tests/test_objectlist.cpp:57–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55}
56
57void TestObjectList::testBehaviorOnDestruction()
58{
59 QPointer<QObject> p(new QObject);
60
61 {
62 ObjectList<QObject> list;
63 list.append(p.data());
64 // nothing is supposed to happen on destruction
65 }
66 QVERIFY(p);
67
68 {
69 ObjectList<QObject> list(ObjectListTracker::CleanupWhenDone);
70 list.append(p.data());
71 }
72 QVERIFY(!p);
73}
74
75#include "moc_test_objectlist.cpp"

Callers

nothing calls this directly

Calls 2

appendMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected