diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-07-05 06:00:29 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-07-05 06:00:29 +0000 |
commit | fecb0e67b23e8b83ba7fc881bb57bc48c0852d62 (patch) | |
tree | 6b8614802f0d01b353bc9ba78aff2090846c198e /kmymoney2/mymoney/mymoneyinstitutiontest.cpp | |
parent | dadc34655c3ab961b0b0b94a10eaaba710f0b5e8 (diff) | |
download | kmymoney-fecb0e67b23e8b83ba7fc881bb57bc48c0852d62.tar.gz kmymoney-fecb0e67b23e8b83ba7fc881bb57bc48c0852d62.zip |
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
Diffstat (limited to 'kmymoney2/mymoney/mymoneyinstitutiontest.cpp')
-rw-r--r-- | kmymoney2/mymoney/mymoneyinstitutiontest.cpp | 34 |
1 files changed, 17 insertions, 17 deletions
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( "<!DOCTYPE TEST>\n" "<INSTITUTION-CONTAINER>\n" " <INSTITUTION sortcode=\"sortcode\" id=\"I00001\" manager=\"manager\" name=\"name\" >\n" @@ -230,7 +230,7 @@ void MyMoneyInstitutionTest::testWriteXML() { void MyMoneyInstitutionTest::testReadXML() { MyMoneyInstitution i; - QString ref_ok = QString( + TQString ref_ok = TQString( "<!DOCTYPE TEST>\n" "<INSTITUTION-CONTAINER>\n" " <INSTITUTION sortcode=\"sortcode\" id=\"I00001\" manager=\"manager\" name=\"name\" >\n" @@ -245,7 +245,7 @@ void MyMoneyInstitutionTest::testReadXML() { " </INSTITUTION>\n" "</INSTITUTION-CONTAINER>\n"); - QString ref_false = QString( + TQString ref_false = TQString( "<!DOCTYPE TEST>\n" "<INSTITUTION-CONTAINER>\n" " <KINSTITUTION sortcode=\"sortcode\" id=\"I00001\" manager=\"manager\" name=\"name\" >\n" @@ -257,8 +257,8 @@ void MyMoneyInstitutionTest::testReadXML() { " </KINSTITUTION>\n" "</INSTITUTION-CONTAINER>\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; |