aboutsummaryrefslogtreecommitdiffhomepage
path: root/Example/Auth/Sample/SettingsViewController.m
diff options
context:
space:
mode:
authorGravatar Zsika Phillip <protocol86@users.noreply.github.com>2018-04-29 19:29:48 -0700
committerGravatar Paul Beusterien <paulbeusterien@google.com>2018-04-29 19:29:48 -0700
commit22a943708d156712a97d29dcd11ee903cb9d8494 (patch)
tree918aa3254d408010679b415b5cbe6fb2866d6cea /Example/Auth/Sample/SettingsViewController.m
parent1476e2bfe5db393ac3b069c1e12d14f91f6b529b (diff)
Adds phone auth testing. (disableAppVerification) (#1192)
Diffstat (limited to 'Example/Auth/Sample/SettingsViewController.m')
-rw-r--r--Example/Auth/Sample/SettingsViewController.m17
1 files changed, 17 insertions, 0 deletions
diff --git a/Example/Auth/Sample/SettingsViewController.m b/Example/Auth/Sample/SettingsViewController.m
index 24a6513..4815f32 100644
--- a/Example/Auth/Sample/SettingsViewController.m
+++ b/Example/Auth/Sample/SettingsViewController.m
@@ -214,9 +214,26 @@ static NSString *truncatedString(NSString *string, NSUInteger length) {
[weakSelf loadTableView];
}],
]],
+ [StaticContentTableViewSection sectionWithTitle:@"Auth Settings" cells:@[
+ [StaticContentTableViewCell cellWithTitle:@"Disable App Verification (Phone)"
+ value:[AppManager auth].settings.
+ appVerificationDisabledForTesting ? @"Yes" : @"No"
+ action:^{
+ [weakSelf toggleDisableAppVerification];
+ [weakSelf loadTableView];
+ }],
+ ]],
]];
}
+/** @fn toggleDisableAppVerification
+ @brief Toggles the appVerificationDisabledForTesting flag on the current Auth instance.
+ */
+- (void)toggleDisableAppVerification {
+ [AppManager auth].settings.appVerificationDisabledForTesting =
+ ![AppManager auth].settings.appVerificationDisabledForTesting;
+}
+
/** @fn toggleAPIHostWithRequestClassName:
@brief Toggles the host name of the server that handles RPCs.
@param requestClassName The name of the RPC request class.