From fecb0e67b23e8b83ba7fc881bb57bc48c0852d62 Mon Sep 17 00:00:00 2001 From: tpearson Date: Tue, 5 Jul 2011 06:00:29 +0000 Subject: TQt4 port kmymoney This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kmymoney@1239855 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kmymoney2/mymoney/mymoneyinstitutiontest.cpp | 34 ++++++++++++++-------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'kmymoney2/mymoney/mymoneyinstitutiontest.cpp') diff --git a/kmymoney2/mymoney/mymoneyinstitutiontest.cpp b/kmymoney2/mymoney/mymoneyinstitutiontest.cpp index ce707ec..bf889b0 100644 --- a/kmymoney2/mymoney/mymoneyinstitutiontest.cpp +++ b/kmymoney2/mymoney/mymoneyinstitutiontest.cpp @@ -161,8 +161,8 @@ void MyMoneyInstitutionTest::testInequality () { void MyMoneyInstitutionTest::testAccountIDList () { MyMoneyInstitution institution; - QStringList list; - QString id; + TQStringList list; + TQString id; // list must be empty list = institution.accountList(); @@ -172,26 +172,26 @@ void MyMoneyInstitutionTest::testAccountIDList () { institution.addAccountId("A000002"); list = institution.accountList(); CPPUNIT_ASSERT(list.count() == 1); - CPPUNIT_ASSERT(list.contains("A000002") == 1); + CPPUNIT_ASSERT(list.tqcontains("A000002") == 1); // adding same account shouldn't make a difference institution.addAccountId("A000002"); list = institution.accountList(); CPPUNIT_ASSERT(list.count() == 1); - CPPUNIT_ASSERT(list.contains("A000002") == 1); + CPPUNIT_ASSERT(list.tqcontains("A000002") == 1); // now add another account institution.addAccountId("A000001"); list = institution.accountList(); CPPUNIT_ASSERT(list.count() == 2); - CPPUNIT_ASSERT(list.contains("A000002") == 1); - CPPUNIT_ASSERT(list.contains("A000001") == 1); + CPPUNIT_ASSERT(list.tqcontains("A000002") == 1); + CPPUNIT_ASSERT(list.tqcontains("A000001") == 1); id = institution.removeAccountId("A000001"); CPPUNIT_ASSERT(id == "A000001"); list = institution.accountList(); CPPUNIT_ASSERT(list.count() == 1); - CPPUNIT_ASSERT(list.contains("A000002") == 1); + CPPUNIT_ASSERT(list.tqcontains("A000002") == 1); } @@ -200,17 +200,17 @@ void MyMoneyInstitutionTest::testWriteXML() { n->addAccountId("A000001"); n->addAccountId("A000003"); - n->setValue(QString("key"), "value"); + n->setValue(TQString("key"), "value"); - QDomDocument doc("TEST"); - QDomElement el = doc.createElement("INSTITUTION-CONTAINER"); + TQDomDocument doc("TEST"); + TQDomElement el = doc.createElement("INSTITUTION-CONTAINER"); doc.appendChild(el); MyMoneyInstitution i("I00001", *n); i.writeXML(doc, el); - QString ref = QString( + TQString ref = TQString( "\n" "\n" " \n" @@ -230,7 +230,7 @@ void MyMoneyInstitutionTest::testWriteXML() { void MyMoneyInstitutionTest::testReadXML() { MyMoneyInstitution i; - QString ref_ok = QString( + TQString ref_ok = TQString( "\n" "\n" " \n" @@ -245,7 +245,7 @@ void MyMoneyInstitutionTest::testReadXML() { " \n" "\n"); - QString ref_false = QString( + TQString ref_false = TQString( "\n" "\n" " \n" @@ -257,8 +257,8 @@ void MyMoneyInstitutionTest::testReadXML() { " \n" "\n"); - QDomDocument doc; - QDomElement node; + TQDomDocument doc; + TQDomElement node; doc.setContent(ref_false); node = doc.documentElement().firstChild().toElement(); @@ -274,7 +274,7 @@ void MyMoneyInstitutionTest::testReadXML() { doc.setContent(ref_ok); node = doc.documentElement().firstChild().toElement(); try { - QStringList alist; + TQStringList alist; alist << "A000001" << "A000003"; i = MyMoneyInstitution(node); @@ -287,7 +287,7 @@ void MyMoneyInstitutionTest::testReadXML() { CPPUNIT_ASSERT(i.city() == "town"); CPPUNIT_ASSERT(i.telephone() == "telephone"); CPPUNIT_ASSERT(i.accountList() == alist); - CPPUNIT_ASSERT(i.value(QString("key")) == "value"); + CPPUNIT_ASSERT(i.value(TQString("key")) == "value"); } catch(MyMoneyException *e) { delete e; -- cgit v1.2.3