-
Notifications
You must be signed in to change notification settings - Fork 46
Add Tools & Scripts that build testapps #41
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
Conversation
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.
This is really big, and thus hard to actually review. I know most of this is being brought over from the internal versions of these files. Can you call out the major changes that had to be done, cause that will make it easier to note what is changing.
@@ -166,7 +166,7 @@ PlayerSettings: | |||
buildNumber: | |||
iOS: 0 | |||
AndroidBundleVersionCode: 1 | |||
AndroidMinSdkVersion: 16 | |||
AndroidMinSdkVersion: 26 |
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'm not a fan of this being updated. We should figure out what the issue here is, because 16 should be fine, and bumping this up just hides the problem.
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.
Update the version for now to unblock the build process.
Shawn created a ticket for this problem, and VJ is working on it. Will revert the change once it problem solved.
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.
To make sure we don't forget to revert it back, do you want to add a TODO in the code and link to the ticket?
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.
We have a ticket. And talked with Shawn and VJ today, we are working on it now.
|
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 skimmed through all the python code and left a few comments, but they look largely good to me. I hope that once I'm more familiar with the Games stacks, I'll be able to review more type of code.
@@ -166,7 +166,7 @@ PlayerSettings: | |||
buildNumber: | |||
iOS: 0 | |||
AndroidBundleVersionCode: 1 | |||
AndroidMinSdkVersion: 16 | |||
AndroidMinSdkVersion: 26 |
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.
To make sure we don't forget to revert it back, do you want to add a TODO in the code and link to the ticket?
scripts/gha/integration_testing/automated_testapp/AutomatedTestRunner.cs
Outdated
Show resolved
Hide resolved
scripts/gha/integration_testing/entitlements/dynamic_links.entitlements
Outdated
Show resolved
Hide resolved
scripts/gha/integration_testing/entitlements/messaging.entitlements
Outdated
Show resolved
Hide resolved
for _, directories, _ in os.walk(iphone_build_dir): | ||
for directory in directories: | ||
if directory.endswith('.app'): |
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.
Would it be simpler if we use glob
here?
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.
Good to know! We use os.walk
in a few other scripts. Maybe worthing have a separate PR solve them at once.
shutil.move(app_path, payload_path) | ||
shutil.make_archive( | ||
payload_path, "zip", root_dir=iphone_build_dir, base_dir="Payload") | ||
shutil.move("%s.%s"%(payload_path, "zip"), ipa_path) |
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.
f-string appears to be the modern way for formatting strings. I think they are more readable than str.format()
and %
operator. It's up to you.
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.
f-string
is a new feature in python 3.6. Our script used to support python 2. But I think that it's worth doing this cleaning for the python scripts.
I feel it will be clearer if this code change is structured as two separate pull requests:
This would make the PR easier to review and faster to merge (go/small-cls). It's okay to me if it's hard to split this time, but maybe starting from next PR, let's be more conscious of the size of our PR. What do you think? |
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.
A few nit comments, this is really an epic PR, great job!
Tested locally with Unity
2017.4.37f1
and2019.2.8f1
.firestore
testapp uses Unity Test Framework, which requires at least Unity 2019.2.Except for firestore in
2017.4.37f1
and iOS analytics testapps, the rest testapps build successfully with All platform:iOS,Android,Win64,OSXUniversal,Linux64
.For in-editor test, MacOS' Gatekeeper (which blocks untrusted binaries) will prevent
playmode
tests on MacOS.MenuScene
,automated_testapp
and etc., under pathscripts/gha/integration_test
scripts/gha
. Modified the scripts and configs for GitHub.To test locally:
Make sure you have Unity 2017.4.37f1 installed and activated.
For iOS, using XCode 10 by default,
For Android, using SDK tool 25.2.*, JAVA_HOME set to JDK8
(For Unity 2019.2.8f1, we need newer JDK, and Android SDK)
python scripts/gha/restore_secrets.py --passphrase ${passphrase}
python scripts/gha/build_testapps.py --t auth,database --u 2017.4.37f1 --p iOS,Android,Win64,OSXUniversal,Linux64 --force_latest_runtime