Compare commits

...

9 Commits

Author SHA1 Message Date
Elisabeth Kulzer
145464d0b1 Detox: Android - Fix latency related tests. 2023-03-07 22:01:58 +01:00
Elisabeth Kulzer
643f81b316 Detox: Android - fix smoke tests. 2023-03-07 16:23:57 +01:00
Weblate
279b601b2a Added translation using Weblate (Arabic) 2023-03-07 10:57:36 +02:00
Tom De Moor
049e763204 Deleted translation using Weblate (Arabic) 2023-03-07 10:57:36 +02:00
Weblate
d6e7889afc Added translation using Weblate (Arabic) 2023-03-07 10:57:36 +02:00
MArtin Johnson
46df588a6a Translated using Weblate (Swedish)
Currently translated at 99.9% (1007 of 1008 strings)

Translation: mattermost-languages-shipped/mattermost-mobile-v2
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-mobile-v2/sv/
2023-03-07 10:57:36 +02:00
Konstantin
a92574cdf3 Translated using Weblate (Russian)
Currently translated at 100.0% (1008 of 1008 strings)

Translation: mattermost-languages-shipped/mattermost-mobile-v2
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-mobile-v2/ru/
2023-03-07 10:57:36 +02:00
mini-bomba
fdd0bed294 Translated using Weblate (Polish)
Currently translated at 100.0% (1008 of 1008 strings)

Translation: mattermost-languages-shipped/mattermost-mobile-v2
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-mobile-v2/pl/
2023-03-07 10:57:36 +02:00
Elisabeth Kulzer
72c5271598 Detox: Fix ios connect issue. (#7187)
Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-07 09:00:39 +01:00
20 changed files with 160 additions and 42 deletions

Binary file not shown.

1
assets/base/i18n/ar.json Normal file
View File

@@ -0,0 +1 @@
{}

View File

@@ -321,7 +321,7 @@
"post_body.check_for_out_of_channel_groups_mentions.message": "nie zostali powiadomieni poprzez tą wzmiankę, ponieważ nie są na kanale. Nie można ich dodać do kanału, ponieważ nie są członkami grup połączonych. Aby dodać je do tego kanału, muszą zostać dodane do połączonych grup.",
"post_body.check_for_out_of_channel_mentions.link.and": " i ",
"post_body.check_for_out_of_channel_mentions.link.private": "dodaj je do tego prywatnego kanału",
"post_body.check_for_out_of_channel_mentions.link.public": "dodaj je do kanału",
"post_body.check_for_out_of_channel_mentions.link.public": "dodać ich do kanału",
"post_body.check_for_out_of_channel_mentions.message_last": "? Będą mieć dostęp do całej historii wiadomości.",
"post_body.check_for_out_of_channel_mentions.message.multiple": "zostały wspomniane, ale nie są w kanale. Czy chciałbyś ",
"post_body.check_for_out_of_channel_mentions.message.one": "został wspomniany, ale nie ma go w kanale. Czy chciałbyś ",

View File

@@ -433,7 +433,7 @@
"mobile.create_direct_message.you": "@{username} - вы",
"mobile.create_direct_message.start": "Начать разговор",
"mobile.create_channel.title": "Новый канал",
"mobile.components.select_server_view.msg_description": "Сервер - это коммуникационный узел вашей команды, доступ к которому осуществляется через уникальный URL-адрес",
"mobile.components.select_server_view.msg_description": "Сервер - это коммуникационный узел вашей команды, доступ к которому осуществляется по уникальному URL-адресу",
"mobile.components.select_server_view.msg_connect": "Давайте подключимся к серверу",
"mobile.components.select_server_view.displayName": "Отображаемое имя",
"mobile.components.select_server_view.displayHelp": "Выберите отображаемое имя для вашего сервера",
@@ -992,5 +992,19 @@
"mobile.calls_recording_start_no_permissions": "У вас нет прав для начала записи. Пожалуйста, попросите ведущего звонка начать запись.",
"mobile.calls_recording_start_in_progress": "Запись уже ведется.",
"mobile.calls_host_rec_error_title": "Что-то пошло не так с записью",
"mobile.calls_host_rec_error": "Пожалуйста, попробуйте записать еще раз. Вы также можете обратиться к системному администратору за помощью в устранении неполадок."
"mobile.calls_host_rec_error": "Пожалуйста, попробуйте записать еще раз. Вы также можете обратиться к системному администратору за помощью в устранении неполадок.",
"notification.no_post": "Сообщение не найдено.",
"notification.no_connection": "Сервер недоступен, и мы не смогли получить уведомления канала / команды.",
"invite.summary.back": "Вернуться назад",
"channel_notification_preferences.unmute_content": "Включить уведомления",
"channel_notification_preferences.thread_replies": "Ответы на обсуждения",
"channel_notification_preferences.reset_default": "Сбросить до значений по умолчанию",
"channel_notification_preferences.notify_about": "Уведомить меня о...",
"channel_notification_preferences.notification.thread_replies": "Уведомлять меня об ответах на обсуждения, за которыми я слежу в этом канале",
"channel_notification_preferences.notification.none": "Ничего",
"channel_notification_preferences.notification.mention": "Только упоминания, личные сообщения",
"channel_notification_preferences.notification.all": "Все новые сообщения",
"channel_notification_preferences.muted_title": "На этом канале уведомления отключены",
"channel_notification_preferences.muted_content": "Вы можете изменить настройки уведомлений, но вы не будете получать уведомления, пока вы не включите их для канала обратно.",
"channel_notification_preferences.default": "(по умолчанию)"
}

View File

@@ -992,5 +992,18 @@
"mobile.calls_recording_start_no_permissions": "Du har inte behörighet att starta en inspelning. Be samtalsvärden att starta en inspelning.",
"mobile.calls_recording_start_in_progress": "En inspelning pågår redan.",
"mobile.calls_host_rec_error_title": "Något gick fel med inspelningen",
"mobile.calls_host_rec_error": "Försök att spela in igen. Du kan också kontakta din systemadministratör för att få hjälp med felsökning."
"mobile.calls_host_rec_error": "Försök att spela in igen. Du kan också kontakta din systemadministratör för att få hjälp med felsökning.",
"notification.no_post": "Meddelandet hittades inte.",
"invite.summary.back": "Gå tillbaka",
"channel_notification_preferences.unmute_content": "Stäng av mjutad kanal",
"channel_notification_preferences.thread_replies": "Svar i trådar",
"channel_notification_preferences.reset_default": "Återställ till standardinställningen",
"channel_notification_preferences.notify_about": "Notifiera mig om...",
"channel_notification_preferences.notification.thread_replies": "Notifiera mig om svar i trådar som jag följer i denna kanal",
"channel_notification_preferences.notification.none": "Inget",
"channel_notification_preferences.notification.mention": "Endast omnämnanden och direktmeddelanden",
"channel_notification_preferences.notification.all": "Alla nya meddelanden",
"channel_notification_preferences.muted_title": "Kanalen är mjutad",
"channel_notification_preferences.muted_content": "Du kan ändra notifieringsinställningarna, men eftersom kanalen är mjutad kommer du inte få notifieringar.",
"channel_notification_preferences.default": "(standard)"
}

View File

@@ -81,6 +81,7 @@ class AccountScreen {
open = async () => {
// # Open account screen
await waitFor(HomeScreen.accountTab).toBeVisible().withTimeout(timeouts.TWO_SEC);
await HomeScreen.accountTab.tap();
return this.toBeVisible();
@@ -92,7 +93,7 @@ class AccountScreen {
await expect(Alert.logoutTitle(serverDisplayName)).toBeVisible();
}
await Alert.logoutButton.tap();
await expect(this.accountScreen).not.toBeVisible();
await waitFor(this.accountScreen).not.toBeVisible().withTimeout(timeouts.TEN_SEC);
};
}

View File

@@ -6,7 +6,7 @@ import {
ProfilePicture,
} from '@support/ui/component';
import {ChannelScreen} from '@support/ui/screen';
import {timeouts, wait} from '@support/utils';
import {isAndroid, timeouts, wait} from '@support/utils';
import {expect} from 'detox';
class ChannelInfoScreen {
@@ -98,6 +98,7 @@ class ChannelInfoScreen {
open = async () => {
// # Open channel info screen
await waitFor(ChannelScreen.headerTitle).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ChannelScreen.headerTitle.tap();
return this.toBeVisible();
@@ -165,6 +166,9 @@ class ChannelInfoScreen {
leaveChannel = async ({confirm = true} = {}) => {
await waitFor(this.leaveChannelOption).toExist().withTimeout(timeouts.TWO_SEC);
if (isAndroid()) {
await this.scrollView.scrollTo('bottom');
}
await this.leaveChannelOption.tap({x: 1, y: 1});
const {
leaveChannelTitle,

View File

@@ -1,7 +1,7 @@
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import {isIos, timeouts, wait} from '@support/utils';
import {isAndroid, isIos, timeouts, wait} from '@support/utils';
import {expect} from 'detox';
class ServerScreen {
@@ -47,7 +47,9 @@ class ServerScreen {
await this.serverUrlInput.replaceText(serverUrl);
await this.serverUrlInput.tapReturnKey();
await this.serverDisplayNameInput.replaceText(serverDisplayName);
await this.serverDisplayNameInput.tapReturnKey();
if (isAndroid()) {
await this.serverDisplayNameInput.tapReturnKey();
}
if (isIos()) {
await this.tapConnectButton();
}

View File

@@ -58,6 +58,7 @@ describe('Channels - Archive Channel', () => {
// # Open a public channel screen, open channel info screen, and tap on archive channel option and confirm
const {channel: publicChannel} = await Channel.apiCreateChannel(siteOneUrl, {type: 'O', teamId: testTeam.id});
await Channel.apiAddUserToChannel(siteOneUrl, testUser.id, publicChannel.id);
await wait(timeouts.TWO_SEC);
await device.reloadReactNative();
await ChannelScreen.open(channelsCategory, publicChannel.name);
await ChannelInfoScreen.open();
@@ -88,6 +89,7 @@ describe('Channels - Archive Channel', () => {
// # Open a public channel screen, open channel info screen, and tap on archive channel option and cancel
const {channel: publicChannel} = await Channel.apiCreateChannel(siteOneUrl, {type: 'O', teamId: testTeam.id});
await Channel.apiAddUserToChannel(siteOneUrl, testUser.id, publicChannel.id);
await wait(timeouts.TWO_SEC);
await device.reloadReactNative();
await ChannelScreen.open(channelsCategory, publicChannel.name);
await ChannelInfoScreen.open();
@@ -105,6 +107,7 @@ describe('Channels - Archive Channel', () => {
// # Open a private channel screen, open channel info screen, and tap on archive channel option and confirm
const {channel: privateChannel} = await Channel.apiCreateChannel(siteOneUrl, {type: 'P', teamId: testTeam.id});
await Channel.apiAddUserToChannel(siteOneUrl, testUser.id, privateChannel.id);
await wait(timeouts.TWO_SEC);
await device.reloadReactNative();
await ChannelScreen.open(channelsCategory, privateChannel.name);
await ChannelInfoScreen.open();

View File

@@ -64,6 +64,7 @@ describe('Channels - Channel Info', () => {
await expect(ChannelInfoScreen.pinnedMessagesOption).toBeVisible();
await expect(ChannelInfoScreen.copyChannelLinkOption).toBeVisible();
await expect(ChannelInfoScreen.editChannelOption).toBeVisible();
await ChannelInfoScreen.scrollView.scrollTo('bottom');
await expect(ChannelInfoScreen.leaveChannelOption).toBeVisible();
await waitFor(ChannelInfoScreen.archiveChannelOption).toBeVisible().whileElement(by.id(ChannelInfoScreen.testID.scrollView)).scroll(50, 'down');
await expect(ChannelInfoScreen.archiveChannelOption).toBeVisible();

View File

@@ -23,7 +23,7 @@ import {
PostOptionsScreen,
ServerScreen,
} from '@support/ui/screen';
import {getRandomId} from '@support/utils';
import {getRandomId, isAndroid} from '@support/utils';
import {expect} from 'detox';
describe('Channels - Channel Post List', () => {
@@ -52,6 +52,10 @@ describe('Channels - Channel Post List', () => {
it('MM-T4773_1 - should match elements on channel screen', async () => {
// # Open a channel screen
await ChannelScreen.open('channels', testChannel.name);
if (isAndroid()) {
await ChannelScreen.back();
await ChannelScreen.open('channels', testChannel.name);
}
// * Verify basic elements on channel screen
await expect(ChannelScreen.backButton).toBeVisible();
@@ -77,6 +81,10 @@ describe('Channels - Channel Post List', () => {
// # Open a channel screen and post a message
const message = `Message ${getRandomId()}`;
await ChannelScreen.open('channels', testChannel.name);
if (isAndroid()) {
await ChannelScreen.back();
await ChannelScreen.open('channels', testChannel.name);
}
await ChannelScreen.postMessage(message);
// * Verify message is added to post list

View File

@@ -7,7 +7,7 @@
// - Use element testID when selecting an element. Create one if none.
// *******************************************************************
import {serverOneUrl} from '@support/test_config';
import {siteOneUrl} from '@support/test_config';
import {
ChannelScreen,
ChannelListScreen,
@@ -17,21 +17,21 @@ import {
ServerScreen,
ChannelInfoScreen,
} from '@support/ui/screen';
import {getAdminAccount, getRandomId} from '@support/utils';
import {getAdminAccount, getRandomId, timeouts} from '@support/utils';
import {expect} from 'detox';
describe('Channels - Convert to Private Channel', () => {
const serverOneDisplayName = 'Server 1';
const siteOneDisplayName = 'Server 1';
beforeAll(async () => {
// # Log in to server as admin
await ServerScreen.connectToServer(serverOneUrl, serverOneDisplayName);
await ServerScreen.connectToServer(siteOneUrl, siteOneDisplayName);
await LoginScreen.login(getAdminAccount());
});
beforeEach(async () => {
// * Verify on channel list screen
await ChannelListScreen.toBeVisible();
await waitFor(ChannelListScreen.channelListScreen).toBeVisible().withTimeout(timeouts.TWO_MIN);
});
afterAll(async () => {

View File

@@ -81,9 +81,10 @@ describe('Channels - Mute and Unmute Channel', () => {
// * Verify channel is muted
await expect(ChannelInfoScreen.unmuteAction).toBeVisible();
await wait(timeouts.FOUR_SEC);
// # Tap on muted action to unmute the channel
await ChannelInfoScreen.unmuteAction.tap();
await ChannelInfoScreen.unmuteAction.longPress();
// * Verify channel is unmuted
await expect(ChannelInfoScreen.muteAction).toBeVisible();

View File

@@ -17,7 +17,7 @@ import {
ServerScreen,
ChannelInfoScreen,
} from '@support/ui/screen';
import {getAdminAccount, getRandomId} from '@support/utils';
import {getAdminAccount, getRandomId, timeouts} from '@support/utils';
import {expect} from 'detox';
describe('Channels - Unarchive Channel', () => {
@@ -32,7 +32,7 @@ describe('Channels - Unarchive Channel', () => {
beforeEach(async () => {
// * Verify on channel list screen
await ChannelListScreen.toBeVisible();
await waitFor(ChannelListScreen.channelListScreen).toBeVisible().withTimeout(timeouts.TWO_MIN);
});
afterAll(async () => {

View File

@@ -23,7 +23,7 @@ import {
PostOptionsScreen,
ServerScreen,
} from '@support/ui/screen';
import {getRandomId} from '@support/utils';
import {getRandomId, timeouts} from '@support/utils';
import {expect} from 'detox';
describe('Messaging - Follow and Unfollow Message', () => {
@@ -67,14 +67,14 @@ describe('Messaging - Follow and Unfollow Message', () => {
// * Verify message is followed by user via post footer
const {postListPostItemFooterFollowingButton} = ChannelScreen.getPostListPostItem(post.id, message);
await expect(postListPostItemFooterFollowingButton).toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Open post options for message and tap on unfollow message option
await ChannelScreen.openPostOptionsFor(post.id, message);
await PostOptionsScreen.followingThreadOption.tap();
// * Verify message is not followed by user via post footer
await expect(postListPostItemFooterFollowingButton).not.toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).not.toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Go back to channel list screen
await ChannelScreen.back();
@@ -91,13 +91,13 @@ describe('Messaging - Follow and Unfollow Message', () => {
// * Verify message is followed by user via post footer
const {postListPostItemFooterFollowingButton} = ChannelScreen.getPostListPostItem(post.id, message);
await expect(postListPostItemFooterFollowingButton).toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Tap on following button via post footer
await postListPostItemFooterFollowingButton.tap();
// * Verify message is not followed by user via post footer
await expect(postListPostItemFooterFollowingButton).not.toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).not.toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Go back to channel list screen
await ChannelScreen.back();

View File

@@ -30,7 +30,7 @@ import {
ServerScreen,
ServerListScreen,
} from '@support/ui/screen';
import {timeouts, wait} from '@support/utils';
import {isAndroid, isIos, timeouts, wait} from '@support/utils';
import {expect} from 'detox';
describe('Server Login - Server List', () => {
@@ -98,7 +98,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
// * Verify second server is active and first server is inactive
await waitFor(ServerListScreen.getServerItemActive(serverTwoDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
@@ -118,7 +123,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
// * Verify third server is active, and first and second servers are inactive
await waitFor(ServerListScreen.getServerItemActive(serverThreeDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
@@ -135,7 +145,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen and tap on third server
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemInactive(serverThreeDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemInactive(serverThreeDisplayName).tap();
@@ -145,7 +160,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen and go back to first server
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemInactive(serverOneDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemInactive(serverOneDisplayName).tap();
});
@@ -156,7 +176,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen, swipe left on first server and tap on edit option
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemActive(serverOneDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemActive(serverOneDisplayName).swipe('left');
await ServerListScreen.getServerItemEditOption(serverOneDisplayName).tap();
@@ -197,7 +222,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen, swipe left on first server and tap on remove option
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemActive(serverOneDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemActive(serverOneDisplayName).swipe('left');
await ServerListScreen.getServerItemRemoveOption(serverOneDisplayName).tap();
@@ -209,7 +239,12 @@ describe('Server Login - Server List', () => {
await Alert.removeButton3.tap();
await wait(timeouts.ONE_SEC);
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
// * Verify first server is removed
await expect(ServerListScreen.getServerItemActive(serverOneDisplayName)).not.toExist();
@@ -228,7 +263,12 @@ describe('Server Login - Server List', () => {
// # Open server list screen, swipe left on third server and tap on logout option
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemInactive(serverThreeDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemInactive(serverThreeDisplayName).swipe('left');
await ServerListScreen.getServerItemLogoutOption(serverThreeDisplayName).tap();
@@ -253,12 +293,27 @@ describe('Server Login - Server List', () => {
// # Open server list screen, attempt to add a server already logged in and with inactive session
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
// await ServerListScreen.closeTutorial();
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await ServerListScreen.addServerButton.tap();
await expect(ServerScreen.headerTitleAddServer).toBeVisible();
await ServerScreen.serverUrlInput.replaceText(serverTwoUrl);
if (isAndroid()) {
await ServerScreen.serverUrlInput.tapReturnKey();
}
await ServerScreen.serverDisplayNameInput.replaceText(serverTwoDisplayName);
await ServerScreen.tapConnectButton();
if (isAndroid()) {
await ServerScreen.serverDisplayNameInput.tapReturnKey();
}
if (isIos()) {
await ServerScreen.tapConnectButton();
}
// * Verify same name server error
const sameNameServerError = 'You are using this name for another server.';
@@ -266,8 +321,17 @@ describe('Server Login - Server List', () => {
// # Attempt to add a server already logged in and with active session, with the same server display name
await ServerScreen.serverUrlInput.replaceText(serverOneUrl);
if (isAndroid()) {
await ServerScreen.serverUrlInput.tapReturnKey();
}
await ServerScreen.serverDisplayNameInput.replaceText(serverOneDisplayName);
await ServerScreen.tapConnectButton();
if (isAndroid()) {
await ServerScreen.serverDisplayNameInput.tapReturnKey();
}
if (isIos()) {
await ServerScreen.tapConnectButton();
}
// * Verify same name server error
await expect(ServerScreen.serverDisplayNameInputError).toHaveText(sameNameServerError);
@@ -275,7 +339,12 @@ describe('Server Login - Server List', () => {
// # Close server screen, open server list screen, log out of second server, and go back to first server
await ServerScreen.close();
await ServerListScreen.open();
await ServerListScreen.serverListScreen.swipe('up');
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemInactive(serverTwoDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);
await ServerListScreen.getServerItemInactive(serverTwoDisplayName).swipe('left');
await ServerListScreen.getServerItemLogoutOption(serverTwoDisplayName).tap();

View File

@@ -81,7 +81,6 @@ describe('Smoke Test - Channels', () => {
// * Verify on the other channel screen
await ChannelScreen.toBeVisible();
await expect(ChannelScreen.headerTitle).toHaveText(testChannel.display_name);
await expect(ChannelScreen.introDisplayName).toHaveText(testChannel.display_name);
// # Go back to channel list screen
await ChannelScreen.back();
@@ -189,6 +188,7 @@ describe('Smoke Test - Channels', () => {
// # Open a channel screen, open channel info screen, and tap on archive channel option and confirm
const {channel} = await Channel.apiCreateChannel(siteOneUrl, {teamId: testTeam.id});
await Channel.apiAddUserToChannel(siteOneUrl, testUser.id, channel.id);
await wait(timeouts.TWO_SEC);
await device.reloadReactNative();
await ChannelScreen.open(channelsCategory, channel.name);
await ChannelInfoScreen.open();

View File

@@ -144,7 +144,7 @@ describe('Smoke Test - Messaging', () => {
await element(by.text('🤡')).tap();
// * Verify reaction is added to the message
await expect(element(by.text('🤡').withAncestor(by.id(`channel.post_list.post.${post.id}`)))).toBeVisible();
await waitFor(element(by.text('🤡').withAncestor(by.id(`channel.post_list.post.${post.id}`)))).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Go back to channel list screen
await ChannelScreen.back();
@@ -161,7 +161,7 @@ describe('Smoke Test - Messaging', () => {
// * Verify message is followed by user via post footer
const {postListPostItem, postListPostItemFooterFollowingButton} = ChannelScreen.getPostListPostItem(post.id, message);
await expect(postListPostItemFooterFollowingButton).toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Tap on following button via post footer
await postListPostItemFooterFollowingButton.tap();

View File

@@ -90,6 +90,7 @@ describe('Smoke Test - Server Login', () => {
if (isIos()) {
await ServerListScreen.serverListTitle.swipe('up');
} else if (isAndroid()) {
await waitFor(ServerListScreen.serverListTitle).toBeVisible().withTimeout(timeouts.TWO_SEC);
await ServerListScreen.serverListTitle.swipe('up', 'fast', 0.1, 0.5, 0.3);
}
await waitFor(ServerListScreen.getServerItemInactive(serverTwoDisplayName)).toBeVisible().withTimeout(timeouts.TEN_SEC);

View File

@@ -131,7 +131,7 @@ describe('Threads - Follow and Unfollow Thread', () => {
// * Verify thread is not followed by user via post footer
const {postListPostItemFooterFollowButton, postListPostItemFooterFollowingButton} = ChannelScreen.getPostListPostItem(parentPost.id, parentMessage);
await expect(postListPostItemFooterFollowButton).toBeVisible();
await waitFor(postListPostItemFooterFollowButton).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Open post options for thread
await ChannelScreen.openPostOptionsFor(parentPost.id, parentMessage);
@@ -143,13 +143,13 @@ describe('Threads - Follow and Unfollow Thread', () => {
await PostOptionsScreen.followThreadOption.tap();
// * Verify thread is followed by user via post footer
await expect(postListPostItemFooterFollowingButton).toBeVisible();
await waitFor(postListPostItemFooterFollowingButton).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Open post options for thread
await ChannelScreen.openPostOptionsFor(parentPost.id, parentMessage);
// * Verify thread is followed by user via post options
await expect(PostOptionsScreen.followingThreadOption).toBeVisible();
await waitFor(PostOptionsScreen.followingThreadOption).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Go back to channel list screen
await PostOptionsScreen.close();
@@ -177,7 +177,7 @@ describe('Threads - Follow and Unfollow Thread', () => {
await GlobalThreadsScreen.openThreadOptionsFor(parentPost.id);
// * Verify thread is followed by user via thread options
await expect(ThreadOptionsScreen.followingThreadOption).toBeVisible();
await waitFor(ThreadOptionsScreen.followingThreadOption).toBeVisible().withTimeout(timeouts.TWO_SEC);
// # Tap on unfollow thread option
await ThreadOptionsScreen.followingThreadOption.tap();