forked from Ivasoft/mattermost-mobile
Detox/E2E: Verification fixes and added a step to post message on direct messages (#6664)
* Detox/E2E: Minor fixes and added known issue tag * Add step to post message on direct message
This commit is contained in:
@@ -252,8 +252,7 @@ describe('Autocomplete - Channel Mention', () => {
|
||||
await ChannelScreen.postInput.typeText(testChannel.name);
|
||||
|
||||
// * Verify channel mention autocomplete contains current channel
|
||||
const {channelMentionItemChannelDisplayName, channelMentionItemChannelName} = Autocomplete.getChannelMentionItem(testChannel.name);
|
||||
await expect(channelMentionItemChannelDisplayName).toHaveText(`${testChannel.display_name}`);
|
||||
await expect(channelMentionItemChannelName).toHaveText(` ~${testChannel.name}`);
|
||||
const {channelMentionItemChannelDisplayName} = Autocomplete.getChannelMentionItem(testChannel.name);
|
||||
await expect(channelMentionItemChannelDisplayName).toHaveText(`${testChannel.display_name} ~${testChannel.name}`);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -21,6 +21,7 @@ import {
|
||||
LoginScreen,
|
||||
ServerScreen,
|
||||
} from '@support/ui/screen';
|
||||
import {timeouts} from '@support/utils';
|
||||
import {expect} from 'detox';
|
||||
|
||||
describe('Autocomplete - Edit Channel Header', () => {
|
||||
@@ -62,6 +63,7 @@ describe('Autocomplete - Edit Channel Header', () => {
|
||||
await CreateOrEditChannelScreen.headerInput.typeText('@');
|
||||
|
||||
// * Verify at-mention list is displayed
|
||||
await waitFor(Autocomplete.sectionAtMentionList).toExist().withTimeout(timeouts.ONE_SEC);
|
||||
await expect(Autocomplete.sectionAtMentionList).toBeVisible();
|
||||
});
|
||||
|
||||
|
||||
@@ -98,7 +98,8 @@ describe('Channels - Create Direct Message', () => {
|
||||
await expect(ChannelScreen.headerTitle).toHaveText(newUserDisplayName);
|
||||
await expect(ChannelScreen.introDisplayName).toHaveText(newUserDisplayName);
|
||||
|
||||
// # Go back to channel list screen
|
||||
// # Post a message and go back to channel list screen
|
||||
await ChannelScreen.postMessage('test');
|
||||
await ChannelScreen.back();
|
||||
await device.reloadReactNative();
|
||||
await ChannelListScreen.toBeVisible();
|
||||
@@ -144,7 +145,8 @@ describe('Channels - Create Direct Message', () => {
|
||||
await expect(ChannelScreen.headerTitle).toHaveText(groupDisplayName);
|
||||
await expect(ChannelScreen.introDisplayName).toHaveText(groupDisplayName);
|
||||
|
||||
// # Go back to channel list screen
|
||||
// # Post a message and go back to channel list screen
|
||||
await ChannelScreen.postMessage('test');
|
||||
await ChannelScreen.back();
|
||||
await device.reloadReactNative();
|
||||
await ChannelListScreen.toBeVisible();
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
|
||||
import {
|
||||
Channel,
|
||||
Post,
|
||||
Setup,
|
||||
Team,
|
||||
User,
|
||||
@@ -112,10 +113,14 @@ describe('Channels - Favorite and Unfavorite Channel', () => {
|
||||
});
|
||||
|
||||
it('MM-T4929_3 - should be able to favorite/unfavorite a direct message channel from channel intro', async () => {
|
||||
// # Open a direct message channel screen, tap on intro favorite action to favorite the channel, and go back to channel list screen
|
||||
// # Open a direct message channel screen, post a message, tap on intro favorite action to favorite the channel, and go back to channel list screen
|
||||
const {user: newUser} = await User.apiCreateUser(siteOneUrl);
|
||||
await Team.apiAddUserToTeam(siteOneUrl, newUser.id, testTeam.id);
|
||||
const {channel: directMessageChannel} = await Channel.apiCreateDirectChannel(siteOneUrl, [testUser.id, newUser.id]);
|
||||
await Post.apiCreatePost(siteOneUrl, {
|
||||
channelId: directMessageChannel.id,
|
||||
message: 'test',
|
||||
});
|
||||
await device.reloadReactNative();
|
||||
await ChannelScreen.open(directMessagesCategory, directMessageChannel.name);
|
||||
await ChannelScreen.introFavoriteAction.tap();
|
||||
|
||||
Reference in New Issue
Block a user