Commit 812b4c11 authored by Laurent Montel's avatar Laurent Montel 😁

Add more autotest

parent 61d03c1c
......@@ -104,15 +104,14 @@ void TitleTest::shouldEqualTitle()
QVERIFY(title == result);
}
#if 0
void TitleTest::shouldParseLanguage()
void TitleTest::shouldParseTitle()
{
QByteArray vcarddata("BEGIN:VCARD\n"
"VERSION:3.0\n"
"N:LastName;FirstName;;;\n"
"UID:c80cf296-0825-4eb0-ab16-1fac1d522a33@xxxxxx.xx\n"
"LANG:fr"
"Title:boo\n"
"REV:2015-03-14T09:24:45+00:00\n"
"FN:FirstName LastName\n"
"END:VCARD\n");
......@@ -120,9 +119,11 @@ void TitleTest::shouldParseLanguage()
KContacts::VCardTool vcard;
const KContacts::AddresseeList lst = vcard.parseVCards(vcarddata);
QCOMPARE(lst.count(), 1);
QCOMPARE(lst.at(0).langs().count(), 1);
QCOMPARE(lst.at(0).extraTitleList().count(), 1);
QCOMPARE(lst.at(0).title(), QStringLiteral("boo"));
}
#if 0
void TitleTest::shouldParseWithoutLanguage()
{
QByteArray vcarddata("BEGIN:VCARD\n"
......
......@@ -35,8 +35,8 @@ private Q_SLOTS:
void shouldAssignExternal();
void shouldSerialized();
void shouldEqualTitle();
void shouldParseTitle();
#if 0
void shouldParseLanguage();
void shouldParseWithoutLanguage();
void shouldCreateVCard();
void shouldCreateVCardWithTwoLang();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment