~renatofilho/address-book-app/fix-1420851

« back to all changes in this revision

Viewing changes to tests/qml/tst_ContactPreviewPage.qml

  • Committer: Renato Araujo Oliveira Filho
  • Date: 2015-02-12 16:51:01 UTC
  • Revision ID: renato.filho@canonical.com-20150212165101-e4oi3ngvwqxhprsh
Create the pageTitle property on ContactPreviewPage to help on tests.

Show diffs side-by-side

added added

removed removed

Lines of Context:
96
96
        function test_preview_contact_with_name()
97
97
        {
98
98
            contactPreviewPage.contact = createContactWithName()
99
 
            tryCompare(contactPreviewPage, "title", "Fulano")
 
99
            tryCompare(contactPreviewPage, "pageTitle", "Fulano")
100
100
        }
101
101
 
102
102
        function test_preview_contact_with_name_and_avatar()
103
103
        {
104
104
            contactPreviewPage.contact = createContactWithNameAndAvatar()
105
 
            tryCompare(contactPreviewPage, "title", "Fulano")
 
105
            tryCompare(contactPreviewPage, "pageTitle", "Fulano")
106
106
            var avatarField = findChild(root, "contactAvatarDetail")
107
107
            tryCompare(avatarField, "avatarUrl", "image://theme/address-book-app")
108
108
        }
113
113
            var contact =  vcardParser.contacts[0]
114
114
            console.debug("Contact: " + contact.phoneNumber.number)
115
115
            contactPreviewPage.contact = contact
116
 
            tryCompare(contactPreviewPage, "title", "Forrest Gump")
 
116
            tryCompare(contactPreviewPage, "pageTitle", "Forrest Gump")
117
117
            // PhoneNumbers
118
118
            // TEL;TYPE=WORK,VOICE:(111) 555-12121
119
119
            // TEL;TYPE=HOME,VOICE:(404) 555-1212