MobileTestCases
1. Inbox Test Cases
Example Config:
Channel Roles: Host/Guest
import { Inbox } from '@messenger-box/platform-mobile';
import { IRoomType } from '@messenger-box/platform-client';
const inboxConfig = {
['//l/inbox']: {
exact: true,
name: 'Inbox',
props: {
initialParams: { channelId: null },
component:(props: any) => (
<Inbox {...props}
channelFilters={{type: IRoomType.Direct,orgName:orgName}}
channelRole={'Guest'}
supportServices={true} />
),
},
},
}
- Inbox with channelFilters (default type direct).
<Inbox channelFilters={{type: IRoomType.Direct}} />
- Inbox with channelFilters (default type direct and orgName null).
<Inbox channelFilters={{type: IRoomType.Direct,orgName:orgName}} />
- Inbox with channelRole (default all type).
<Inbox channelFilters={{type: IRoomType.Direct}} channelRole={'Guest'} />
- Inbox with supportServices (default false).
<Inbox channelFilters={{type: IRoomType.Direct}} supportServices={true} />
- Expected Result: The inbox should display a list of all direct channels by default.Additionally, it should support filtering the displayed channels based on specified criteria (channelFilters).When supportServices=true, it should display all fitered channels with all support service channels (By default supportServices=false).
2. Inbox Conversation Test Cases
Example Config:
import { DialogMessages } from '@messenger-box/platform-mobile';
import { IRoomType } from '@messenger-box/platform-client';
const inboxConversationConfig = {
['//inbox/dialogmessage']: {
exact: true,
name: 'Inbox.DialogMessages',
props: {
component:(props: any) => (
<DialogMessages {...props}
channelId={props?.route?.params?.channelId}
role={'Guest'}
isShowThreadMessage={true}
/>
),
},
},
}
- Inbox Conversation with ChannelId.
<DialogMessages channelId={props?.route?.params?.channelId} />
- Inbox Service Conversation with ChannelId and postParentId.
<DialogThreadMessages
channelId={props?.route?.params?.channelId}
postParentId={props?.route?.params?.postParentId}
/>
- Inbox Conversation with Role.
<DialogMessages channelId={props?.route?.params?.channelId} role={'Guest'} />
- Inbox Conversation with Thread Messages (Default true).
<DialogMessages
channelId={props?.route?.params?.channelId}
isShowThreadMessage={false} />
- Expected Result: The inbox conversation component should display a list of all direct channel messages by default for given channelId.Additionally, it should support filtering the displayed channel messages based on specified criteria (role and isShowThreadMessage).When isShowThreadMessage=false, it should display all fitered channel messages with thread messages view disabled (By default isShowThreadMessage=true).