OPVault: Use Text instead of Name for attribute and section names

* Fix #6303 - the text attribute in 1Password contains the actual text seen in 1Password whereas the name attribute may contain a ref pointer and not a name.
This commit is contained in:
Jonathan White
2021-03-23 23:42:31 -04:00
parent ca8abecc4b
commit 871c4fffdd
3 changed files with 12 additions and 19 deletions

View File

@@ -97,10 +97,10 @@ void TestOpVaultReader::testReadIntoDatabase()
entry = db->rootGroup()->findEntryByPath("/Credit Card/My Credit Card");
QVERIFY(entry);
auto attr = entry->attributes();
QCOMPARE(attr->value("cardholder"), QStringLiteral("Team KeePassXC"));
QVERIFY(!attr->value("validFrom").isEmpty());
QCOMPARE(attr->value("details_pin"), QStringLiteral("1234"));
QVERIFY(attr->isProtected("details_pin"));
QCOMPARE(attr->value("cardholder name"), QStringLiteral("Team KeePassXC"));
QVERIFY(!attr->value("valid from").isEmpty());
QCOMPARE(attr->value("Additional Details_PIN"), QStringLiteral("1234"));
QVERIFY(attr->isProtected("Additional Details_PIN"));
// Confirm address fields
entry = db->rootGroup()->findEntryByPath("/Identity/Team KeePassXC");