Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/SubscriptAvatar.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ function SubscriptAvatar(props) {
>
<View>
<Avatar
containerStyles={StyleUtils.getWidthAndHeightStyle(StyleUtils.getAvatarSize(props.size || CONST.AVATAR_SIZE.DEFAULT))}
containerStyles={StyleUtils.getAvatarStyle(props.size || CONST.AVATAR_SIZE.DEFAULT)}
source={props.mainAvatar.source}
size={props.size || CONST.AVATAR_SIZE.DEFAULT}
name={props.mainAvatar.name}
Expand Down
8 changes: 5 additions & 3 deletions tests/unit/SidebarFilterTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ describe('Sidebar', () => {
// When Onyx is updated to contain that report
.then(() =>
Onyx.multiSet({
[ONYXKEYS.IS_LOADING_REPORT_DATA]: false,
[`${ONYXKEYS.COLLECTION.REPORT}${report.reportID}`]: report,
}),
)
Expand All @@ -100,7 +101,7 @@ describe('Sidebar', () => {
it('includes an empty chat report if it has a draft', () => {
LHNTestUtils.getDefaultRenderedSidebarLinks();

// Given a new report
// Given a new report with a draft text
const report = {
...LHNTestUtils.getFakeReport([1, 2], 0),
hasDraft: true,
Expand All @@ -111,12 +112,13 @@ describe('Sidebar', () => {
// When Onyx is updated to contain that report
.then(() =>
Onyx.multiSet({
[`${ONYXKEYS.COLLECTION.REPORT}${report.reportID}`]: report,
[ONYXKEYS.IS_LOADING_REPORT_DATA]: false,
[ONYXKEYS.PERSONAL_DETAILS_LIST]: LHNTestUtils.fakePersonalDetails,
[`${ONYXKEYS.COLLECTION.REPORT}${report.reportID}`]: report,
}),
)

// Then no reports are rendered in the LHN
// Then the report should be rendered in the LHN since it has a draft
.then(() => {
const hintText = Localize.translateLocal('accessibilityHints.chatUserDisplayNames');
const displayNames = screen.queryAllByLabelText(hintText);
Expand Down