Package com.tomtom.ivi.platform.contacts.api.testing.servicemockextension

Types

Link copied to clipboard
class ContactsTestIviDataSource(jumpingSupported: Boolean = true, keyReuseSupported: Boolean = true) : AbstractTestIviDataSource<ContactsDataSourceElement, ContactsDataSourceQuery>

Test data source which can be used during testing of contacts.

Functions

Link copied to clipboard
@MainThread
fun ContactsServiceMock.addFindContactByPhoneNumberQuery(phoneNumberToFind: String, contactToReturn: Contact?)

Add query when finding a contact by phone number.

Link copied to clipboard
@MainThread
fun ContactsServiceMock.addQueryWithResult(query: ContactsDataSourceQuery, result: List<ContactsDataSourceElement>)

Add or update a datasource query.

Link copied to clipboard
@MainThread
fun ContactsServiceMock.addSearchQuery(searchText: String, contactsToReturn: List<Contact>?)

Add query when searching for a contact.

Link copied to clipboard
@MainThread
fun ContactsServiceMock.clearContacts()

Clears the list of contacts.

Link copied to clipboard
@MainThread
fun ContactsServiceMock.defaultInit()

Performs a default initialization of the contacts service mock which makes the service available.

Link copied to clipboard
@MainThread
fun ContactsServiceMock.setContacts(contactsList: List<Contact>)

Add or update a list contacts.