MetaMask / metamask-mobile

Mobile web browser providing access to websites that use the Ethereum blockchain
https://metamask.io
Other
2.16k stars 1.11k forks source link

[Batch 1/7] Remove all instances of strings in TestID property in the app code #7865

Closed cortisiko closed 11 months ago

cortisiko commented 11 months ago

Description

We have instances where testIDs are not consistently stored in variables. This lack of uniformity can lead to redundant testID declarations throughout the codebase, resulting in code that is harder to maintain and prone to errors.

For instance, consider the following code snippet: testID={'request-qrcode-button'}. This line directly specifies a testID value within the code, and similar declarations may be scattered throughout the codebase.

A more effective and best-practice approach is to store the testID value as a variable and then reference that variable when defining the testID property. By doing so, we centralize the testID values, reducing redundancy and making it easier to manage and maintain these identifiers throughout the codebase. This approach enhances code consistency and reduces the likelihood of introducing errors, ultimately contributing to a more robust and maintainable codebase.

Technical details:

Replace all string definitions used for testIDs. For example: testID={BrowserUrlModalSelectorsIDs.CONTAINER} All variables should be group by the file where they're being call All variables should be group in a JSON File structure should follow a similar structure as the main app structure

Acceptance Criteria

cortisiko commented 11 months ago

Hey team! Please add your planning poker estimate with Zenhub @Andepande @chrisleewilcox @SamuelSalas