-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
e2e: added money request flow e2e test #52751
base: main
Are you sure you want to change the base?
Changes from 39 commits
3af050b
c55d0de
0994d6f
513340f
f3ed8a1
2123207
4913fdc
606ac25
3b54445
e8ceb29
7e14df1
128b4e7
a41b9bb
335eb12
04cade1
ab157c0
c2f9221
545e896
9d39e16
951543c
1b5e9d7
9e660ba
e4c77b7
ef04655
b6f51f2
6c69904
7bc9f08
1019668
e25f200
e21c158
3f58021
204a90a
12020d5
571e10a
6ac6946
066807f
8486a23
1fb95a9
7c7f2ec
490ccf4
4db92d6
1cbfd6e
11c12f5
5eca3fd
82fb23d
c953dd2
5740d37
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,12 +27,13 @@ type TabSelectorProps = MaterialTopTabBarProps & { | |
type IconAndTitle = { | ||
icon: IconAsset; | ||
title: string; | ||
testID?: string; | ||
}; | ||
|
||
function getIconAndTitle(route: string, translate: LocaleContextProps['translate']): IconAndTitle { | ||
switch (route) { | ||
case CONST.TAB_REQUEST.MANUAL: | ||
return {icon: Expensicons.Pencil, title: translate('tabSelector.manual')}; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there another way we could do this? I don't love updating this function only in this certain case... There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Let me check it There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We need to mark the elements we're waiting for before rendering so we can manipulate them further. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can we maybe just update the function to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It makes sense, I'll add this right now. Thanks! |
||
return {icon: Expensicons.Pencil, title: translate('tabSelector.manual'), testID: 'manual'}; | ||
case CONST.TAB_REQUEST.SCAN: | ||
return {icon: Expensicons.ReceiptScan, title: translate('tabSelector.scan')}; | ||
case CONST.TAB.NEW_CHAT: | ||
|
@@ -70,7 +71,7 @@ function TabSelector({state, navigation, onTabPress = () => {}, position, onFocu | |
const activeOpacity = getOpacity({routesLength: state.routes.length, tabIndex: index, active: true, affectedTabs: affectedAnimatedTabs, position, isActive}); | ||
const inactiveOpacity = getOpacity({routesLength: state.routes.length, tabIndex: index, active: false, affectedTabs: affectedAnimatedTabs, position, isActive}); | ||
const backgroundColor = getBackgroundColor({routesLength: state.routes.length, tabIndex: index, affectedTabs: affectedAnimatedTabs, theme, position, isActive}); | ||
const {icon, title} = getIconAndTitle(route.name, translate); | ||
const {icon, title, testID} = getIconAndTitle(route.name, translate); | ||
|
||
const onPress = () => { | ||
if (isActive) { | ||
|
@@ -103,6 +104,7 @@ function TabSelector({state, navigation, onTabPress = () => {}, position, onFocu | |
inactiveOpacity={inactiveOpacity} | ||
backgroundColor={backgroundColor} | ||
isActive={isActive} | ||
testID={testID} | ||
shouldShowLabelWhenInactive={shouldShowLabelWhenInactive} | ||
/> | ||
); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adhorodyski any feedback here on the event names?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looking into it