Skip to content

Conversation

@jonsimantov
Copy link
Contributor

@jonsimantov jonsimantov commented Mar 15, 2021

This change updates the integration_tests workflow so that it can download a packaged SDK from GHA and build the integration tests against it, instead of against the SDK source.

With that change, we no longer need to duplicate the integration test code in the C++ packaging workflow.

Instead, the C++ packaging workflow directly invokes the integration_tests workflow at the end via the GitHub REST API.

(Note that because you cannot invoke another workflow with the same GITHUB_TOKEN that your workflow is already using due to a limitation in GitHub actions, the packaging workflow fetches a new GitHub App token to use for the request.)

@google-cla google-cla bot added the cla: yes label Mar 15, 2021
set the matrix target to "openssl" but just treat it like boringssl later.
(workflow_dispatch only works on branch names, not commit IDs.) Add error checking to GitHub API request.
@jonsimantov jonsimantov marked this pull request as ready for review March 16, 2021 06:15
@jonsimantov jonsimantov requested review from DellaBitta and a-maurice and removed request for DellaBitta and a-maurice March 16, 2021 06:15
@jonsimantov jonsimantov marked this pull request as draft March 16, 2021 06:25
@jonsimantov jonsimantov marked this pull request as ready for review March 16, 2021 07:06
@DellaBitta
Copy link
Contributor

DellaBitta commented Mar 16, 2021

The expanded matrix was meant to also expand the build configurations we use, including building across multiple XCode targets, which we do in some other workflows. I thought this was important for our packaging workflows, too, and in my head this would have complicated the script. But now I'm realizing that we only ship one version of the packaged SDK, so why would our CI build multiple Xcode versions of it, etc. Is this your philosophy, too?

Copy link
Contributor

@DellaBitta DellaBitta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some suggestions. Let me know what you think.

hashCommand: "sha256sum"
# Xcode version 12 is the version we build the SDK with.
# Our MacOS runners will use the version in /Applications/Xcode_${xcodeVersion}.app
xcodeVersion: "12"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can remove this env now.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's still needed, because it controls what xcode version the SDK is built with.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code sudo xcode-select -s /Applications/Xcode_${{ env.xcodeVersion }}.app/Contents/Developer has been removed below. Is there something else in here that uses it? Some silent GHA observance of the variable?

@jonsimantov
Copy link
Contributor Author

The expanded matrix was meant to also expand the build configurations we use, including building across multiple XCode targets, which we do in some other workflows. I thought this was important for our packaging workflows, too, and in my head this would have complicated the script. But now I'm realizing that we only ship one version of the packaged SDK, so why would our CI build multiple Xcode versions of it, etc. Is this your philosophy, too?

That was my thought. We build and ship the binary SDK in a single set of configurations. I am happy to keep the SDK packaging matrix in this workflow, and the test matrix in the script. The packaging matrix should never change in the normal course of development.

Copy link
Contributor

@DellaBitta DellaBitta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please double check on that xcodeVersion, but otherwise a-ok.

@jonsimantov jonsimantov enabled auto-merge (squash) March 16, 2021 18:09
@jonsimantov jonsimantov merged commit 0b5b214 into main Mar 16, 2021
@firebase firebase locked and limited conversation to collaborators Apr 16, 2021
@jonsimantov jonsimantov deleted the feature/js-build-integration-tests-packaged branch July 1, 2021 21:08
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

2 participants