Skip to content
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

React Native tests with pre-release native notifiers #1367

Merged
merged 9 commits into from
Apr 28, 2021

Conversation

twometresteve
Copy link
Contributor

@twometresteve twometresteve commented Apr 22, 2021

Goal

Provides a mechanism for running integration test of the React Native notifier, using the pre-release Android and Cocoa notifiers from their respective next branches.

Design

The RN_INTEGRATION build environment variable can be set (to "true") either on a Buildkite schedule, trigger step, or when creating a build manually. If set, the pipeline will pull in and build the latest next version of bugsnag-android and bugsnag-cocoa before publishing the notifier. It will then run only the React Native e2e tests.

If run in this mode, the version for the published notifier is based on the current timestamp, rather than the current commit Id of bugsnag-js. Publishing is skipped if the same version is used as a previous build and even though bugsnag-js may not have changed, the native notifier may have.

An improvement to the current would be to somehow build in a check that the latest native notifiers really have been build in, but I couldn't think of a way to achieve that.

Testing

Covered by CI and inspection of the logs. I've also run it three times via a schedule.

@github-actions
Copy link

github-actions bot commented Apr 22, 2021

@bugsnag/browser bundle size diff

Minified Minfied + Gzipped
Before 40.86 kB 12.61 kB
After 40.86 kB 12.61 kB
± No change No change

code coverage diff

Coverage values did not change👌.

Total:

Lines Branches Functions Statements
0%(+0%) 0%(+0%) 0%(+0%) 0%(+0%)

Generated by 🚫 dangerJS against 066497b

@twometresteve twometresteve force-pushed the tms/react-native-integration-2 branch 3 times, most recently from 7157887 to 34ccbf9 Compare April 23, 2021 07:57
@twometresteve twometresteve changed the base branch from next to tms/license-audit April 23, 2021 08:01
@twometresteve twometresteve marked this pull request as ready for review April 23, 2021 08:02
Base automatically changed from tms/license-audit to next April 26, 2021 09:49
@nickdowell
Copy link
Contributor

The logic LGTM, but I find RN_INTEGRATION to be quite a vague name, whereas something like BUILD_WITH_LATEST_NATIVE_NOTIFIERS would be more obvious 🙃

Copy link
Contributor

@bengourley bengourley left a comment

Choose a reason for hiding this comment

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

Agree with Nick's comment about the env var name. Also a question about repeated builds/caching to avoid building exactly the same release more than once.

Otherwise LGTM.

scripts/common.js Show resolved Hide resolved
@twometresteve
Copy link
Contributor Author

The logic LGTM, but I find RN_INTEGRATION to be quite a vague name, whereas something like BUILD_WITH_LATEST_NATIVE_NOTIFIERS would be more obvious 🙃

Changing to BUILD_RN_WITH_LATEST_NATIVES - slightly shorter whilst also mentioning React Native.

@twometresteve twometresteve force-pushed the tms/react-native-integration-2 branch from 34ccbf9 to 066497b Compare April 28, 2021 07:04
@twometresteve twometresteve merged commit b33d140 into next Apr 28, 2021
@twometresteve twometresteve deleted the tms/react-native-integration-2 branch April 28, 2021 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants