-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[No QA] [TS migration] Migrate 'E2E' lib to TypeScript #28896
Conversation
# Conflicts: # src/types/onyx/Report.ts
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.
LGTM
@@ -1,4 +1,7 @@ | |||
export default () => ({ | |||
/* eslint-disable @typescript-eslint/naming-convention */ |
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.
There is a discussion
which I assume that will resolve issues with bad naming convention and we will be able to sent proper vars names to backed. Just an FYI
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.
@kubabutkiewicz In this file bad naming is caused by mocked data fields like report_98258458
, for example, so I guess we can't do anything
# Conflicts: # src/types/onyx/Policy.ts # src/types/onyx/ReportAction.ts
# Conflicts: # src/CONST.ts
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.
LGTM
@@ -244,6 +244,76 @@ const CONST = { | |||
NEW_DOT_CATEGORIES: 'newDotCategories', | |||
NEW_DOT_TAGS: 'newDotTags', | |||
NEW_DOT_SAML: 'newDotSAML', | |||
PDF_META_STORE: 'pdfMetaStore', |
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.
Can you give a bit of context here? What is the source of all these new properties?
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.
@blazejkustra CONST.BETAS is used in Beta type
There are two apiMocks that set betas, inside openApp.ts and signinUser.ts
So without these new properties, it gives an error like this:
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.
I am working on removing all useless ones, and this change made it 10x harder in this repo 😞
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.
@flodnv Why it made harder for you? Can you give a bit more context?
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.
Because now I have to check if all of these betas are used, which they probably are not...
It would have been better to update the mocks to match the code instead of the opposite, which I think is probably almost always preferred (why mock something that does not exist / is not used?)
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.
Fixed here: #31783
@eVoloshchak Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
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.
LGTM!
# Conflicts: # src/ONYXKEYS.ts # src/types/onyx/Report.ts # src/types/onyx/ReportAction.ts
# Conflicts: # metro.config.js # src/libs/E2E/API.mock.ts # src/libs/E2E/isE2ETestSession.native.js # src/libs/E2E/reactNativeLaunchingTest.ts # src/libs/E2E/tests/appStartTimeTest.e2e.ts
@eVoloshchak I guess this PR has run out of your radar, it would be great if you could take a look at it this week |
# Conflicts: # src/CONST.ts
# Conflicts: # src/libs/E2E/API.mock.ts # src/libs/E2E/apiMocks/openReport.ts # src/libs/E2E/client.ts # src/types/onyx/Response.ts # tests/e2e/ADDING_TESTS.md
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.
lgtm 😄
ON HOLD till #30793 is merged |
# Conflicts: # src/libs/E2E/tests/appStartTimeTest.e2e.ts
I've merged the latest main and updated tests steps, now it's all yours @eVoloshchak :) |
# Conflicts: # src/libs/E2E/apiMocks/openReport.ts # src/types/onyx/Report.ts
@eVoloshchak kind bump 😄 |
Reviewer Checklist
Screenshots/Videos |
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.
LGTM
We did not find an internal engineer to review this PR, trying to assign a random engineer to #24933 as well as to this PR... Please reach out for help on Slack if no one gets assigned! |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/madmax330 in version: 1.3.99-0 🚀
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.99-0 🚀
|
🚀 Deployed to staging by https://github.com/madmax330 in version: 1.4.0-0 🚀
|
Details
[TS migration] Migrate 'E2E' lib to TypeScript
Fixed Issues
$ #24933
PROPOSAL: N/A
Tests
To test that it works as expected, you need to run E2E tests locally.
More information about E2E tests can be found in the related README file and the testRunner file.
Some steps of the easiest way to test from me:
test
andapktool
installedtest
simulatorbundle install
$ANDROID_SDK_ROOT
defined, update it manually to your Android SDK path in this line. You can find the actual location of the SDK in the Android Studio "Settings" dialog, under Languages & Frameworks → Android SDK.npm run test:e2e
, it will take some time for the builds to be generated and tests to pass.tests/e2e/results/output.md
file.Offline tests
N/A
QA Steps
N/A
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
output.md