mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-02-04 08:55:31 -05:00
Improve entry test.
This commit is contained in:
parent
6ee781a608
commit
57b0c17733
@ -25,7 +25,7 @@
|
||||
void TestEntry::testHistoryItemDeletion()
|
||||
{
|
||||
Entry* entry = new Entry();
|
||||
Entry* historyEntry = new Entry();
|
||||
QPointer<Entry> historyEntry = new Entry();
|
||||
|
||||
entry->addHistoryItem(historyEntry);
|
||||
QCOMPARE(entry->historyItems().size(), 1);
|
||||
@ -34,6 +34,9 @@ void TestEntry::testHistoryItemDeletion()
|
||||
historyEntriesToRemove.append(historyEntry);
|
||||
entry->removeHistoryItems(historyEntriesToRemove);
|
||||
QCOMPARE(entry->historyItems().size(), 0);
|
||||
QVERIFY(historyEntry.isNull());
|
||||
|
||||
delete entry;
|
||||
}
|
||||
|
||||
QTEST_GUILESS_MAIN(TestEntry)
|
||||
|
Loading…
x
Reference in New Issue
Block a user