Skip to content

Expo Maze Runner tests for feature flags #1576

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

Merged

Conversation

imjoehaines
Copy link
Contributor

Goal

Adds some maze runner tests for feature flags to the Expo test suite

@imjoehaines imjoehaines requested a review from a team November 9, 2021 15:18
Comment on lines +67 to +70
// reset the bugsnag client so tests don't interfere wtih eachother
bugsnagClient.clearFeatureFlags()
bugsnagClient.removeOnError(addFeatureFlagsOnError)
bugsnagClient.removeOnError(clearFeatureFlagsOnError)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We don't relaunch the app between tests (or if we do that doesn't reset the notifier) so feature flags and callbacks added in previous tests will stick around

I don't think it's possible to use a new client for this because of unhandled exceptions. If both clients report unhandled exceptions then the tests are flakey because sometimes you'll get two events (one from each client). If we create a new client to attach feature flags to, unhandled exceptions won't be sent with those flags because they're on the wrong client

@github-actions
Copy link

github-actions bot commented Nov 9, 2021

@bugsnag/browser bundle size diff

Minified Minfied + Gzipped
Before 42.81 kB 13.06 kB
After 42.81 kB 13.06 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 b70e731

@imjoehaines imjoehaines merged commit 3dc87d9 into integration/feature-flags Nov 10, 2021
@imjoehaines imjoehaines deleted the feature-flags/expo-maze-runner-tests branch November 10, 2021 17:53
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.

2 participants