Skip to content

Commit

Permalink
fix unit test and browser JS warning (mattermost#3087)
Browse files Browse the repository at this point in the history
  • Loading branch information
saturninoabril authored and sudheerDev committed Jul 12, 2019
1 parent 6a80b99 commit 13f9f35
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ describe('components/ChannelSelectorModal', () => {
onChannelsSelected: jest.fn(),
groupID: '',
actions: {
loadChannels: jest.fn(() => Promise.resolve({})),
loadChannels: jest.fn(() => Promise.resolve({data: []})),
setModalSearchTerm: jest.fn(() => Promise.resolve()),
searchChannels: jest.fn(() => Promise.resolve({})),
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -570,6 +570,7 @@ function createSetHeaderButton(channel) {
className={'intro-links color--link'}
dialogType={EditChannelHeaderModal}
dialogProps={{channel}}
modalId={'setChannelHeader'}
>
<EditIcon/>
{message}
Expand Down
2 changes: 1 addition & 1 deletion components/post_view/post_list/post_list.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const actionsProp = {
loadPostsAround: jest.fn().mockImplementation(() => Promise.resolve({atLatestMessage: true, atOldestmessage: true})),
loadUnreads: jest.fn().mockImplementation(() => Promise.resolve({atLatestMessage: true, atOldestmessage: true})),
loadPosts: jest.fn().mockImplementation(() => Promise.resolve({moreToLoad: false})),
syncPostsInChannel: jest.fn(),
syncPostsInChannel: jest.fn().mockResolvedValue({}),
loadLatestPosts: jest.fn().mockImplementation(() => Promise.resolve({atLatestMessage: true, atOldestmessage: true})),
checkAndSetMobileView: jest.fn(),
};
Expand Down

0 comments on commit 13f9f35

Please sign in to comment.