This repository was archived by the owner on Feb 5, 2025. It is now read-only.
Add flag to control the addition of 1Password buttons #624
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR adds a new flag
enableOnePasswordtoWordPressAuthenticatorConfiguration. This flag controls the addition of 1Password buttons to the UI.I also refactored
OnePasswordFacadeto make it more testable.References: wordpress-mobile/WordPress-iOS#17516
This is the second PR that tackles this issue. Planned PRs:
Screenshots
No changes in GetStartedViewController, PasswordViewController or SiteCredentialsViewController.
Testing
I added unit tests to ensure that OnePasswordFacade's computed variable
isOnePasswordEnabled- which controls that addition of 1Password buttons - considers both the new flag and 1Password availability.To test this use the WordPress iOS PR. You need to test on a real device that has 1Password installed.
What to test
WordPressAuthenticationManagerand verify that the old behavior is maintained.Associated PRs
WordPress iOS PR: wordpress-mobile/WordPress-iOS#17596