VulpesOS/gaia/apps/communications/contacts/test/marionette/lib/sms.js
OverSu b38dea0597 Publish Vulpes Preview 15 sources for desktop, Android and Tundra
Share Gaia assets and adapters, keep private profiles and development documents local, and update both public READMEs.
2026-09-30 23:13:03 +02:00

40 lines
782 B
JavaScript
Executable file

'use strict';
/**
* Abstraction around sms app.
* This file can be moved to the sms app once we
* implement sms marionette tests.
* @constructor
* @param {Marionette.Client} client for operations.
*/
function Sms(client) {
this.client = client;
}
/**
* @type String Origin of sms app
*/
Sms.URL = 'app://sms.gaiamobile.org';
Sms.Selectors = {
listCompose: '#icon-add',
threadAddContact: '#messages-contact-pick-button'
};
Sms.prototype = {
/**
* Launches sms app and focuses on frame.
*/
launch: function() {
this.client.apps.launch(Sms.URL);
this.client.apps.switchToApp(Sms.URL);
this.client.helper.waitForElement('body');
},
relaunch: function() {
this.client.apps.close(Sms.URL);
this.launch();
}
};
module.exports = Sms;