Skip to content

Commit 217e0a4

Browse files
committed
warnings
1 parent d5115e8 commit 217e0a4

File tree

1 file changed

+35
-35
lines changed

1 file changed

+35
-35
lines changed

FirebaseAuth/Tests/Unit/ObjCAPITests.m

+35-35
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
@import FirebaseCore;
1818
@import FirebaseAuth;
1919

20-
#if !TARGET_OS_MACOS && !TARGET_OS_WATCHOS
20+
#if !TARGET_OS_OSX && !TARGET_OS_WATCH
2121
@interface AuthUIImpl : NSObject <FIRAuthUIDelegate>
2222
- (void)dismissViewControllerAnimated:(BOOL)flag completion:(void (^_Nullable)(void))completion;
2323
- (void)presentViewController:(nonnull UIViewController *)viewControllerToPresent
@@ -61,7 +61,7 @@ - (void)FIRActionCodeSettings_h {
6161
[codeSettings setAndroidPackageName:@"name" installIfNotAvailable:NO minimumVersion:@"1.1"];
6262
BOOL b = [codeSettings handleCodeInApp];
6363
b = [codeSettings androidInstallIfNotAvailable];
64-
NSURL *u = [codeSettings URL];
64+
__unused NSURL *u = [codeSettings URL];
6565
NSString *s = [codeSettings iOSBundleID];
6666
s = [codeSettings androidPackageName];
6767
s = [codeSettings androidMinimumVersion];
@@ -70,29 +70,29 @@ - (void)FIRActionCodeSettings_h {
7070

7171
- (void)FIRAuthAdditionalUserInfo_h:(FIRAdditionalUserInfo *)additionalUserInfo {
7272
NSString *s = [additionalUserInfo providerID];
73-
BOOL b = [additionalUserInfo isNewUser];
74-
NSDictionary<NSString *, NSObject *> *dict = [additionalUserInfo profile];
73+
__unused BOOL b = [additionalUserInfo isNewUser];
74+
__unused NSDictionary<NSString *, NSObject *> *dict = [additionalUserInfo profile];
7575
s = [additionalUserInfo username];
7676
}
7777

7878
- (void)ActionCodeOperationTests:(FIRActionCodeInfo *)info {
79-
FIRActionCodeOperation op = [info operation];
79+
__unused FIRActionCodeOperation op = [info operation];
8080
NSString *s = [info email];
8181
s = [info previousEmail];
8282
}
8383

8484
- (void)ActionCodeURL:(FIRActionCodeURL *)url {
85-
FIRActionCodeOperation op = [url operation];
85+
__unused FIRActionCodeOperation op = [url operation];
8686
NSString *s = [url APIKey];
8787
s = [url code];
88-
NSURL *u = [url continueURL];
88+
__unused NSURL *u = [url continueURL];
8989
s = [url languageCode];
9090
}
9191

9292
- (void)authProperties:(FIRAuth *)auth {
93-
BOOL b = [auth shareAuthStateAcrossDevices];
93+
__unused BOOL b = [auth shareAuthStateAcrossDevices];
9494
[auth setShareAuthStateAcrossDevices:YES];
95-
FIRUser *u = [auth currentUser];
95+
__unused FIRUser *u = [auth currentUser];
9696
NSString *s = [auth languageCode];
9797
[auth setLanguageCode:s];
9898
FIRAuthSettings *settings = [auth settings];
@@ -103,7 +103,7 @@ - (void)authProperties:(FIRAuth *)auth {
103103
s = [auth customAuthDomain];
104104
[auth setCustomAuthDomain:s];
105105
#if TARGET_OS_IOS
106-
NSData *d = [auth APNSToken];
106+
__unused NSData *d = [auth APNSToken];
107107
auth.APNSToken = [[NSData alloc] init];
108108
#endif
109109
}
@@ -197,7 +197,7 @@ - (void)FIRAuth_h:(FIRAuth *)auth
197197
[auth getStoredUserForAccessGroup:@"user" error:&error];
198198
}
199199

200-
#if !TARGET_OS_MACOS
200+
#if !TARGET_OS_OSX
201201
- (void)FIRAuthAPNSTokenType_h {
202202
FIRAuthAPNSTokenType t = FIRAuthAPNSTokenTypeProd;
203203
t = FIRAuthAPNSTokenTypeSandbox;
@@ -210,9 +210,9 @@ - (NSString *)authCredential:(FIRAuthCredential *)credential {
210210
}
211211

212212
- (void)authDataResult:(FIRAuthDataResult *)result {
213-
FIRUser *u = [result user];
214-
FIRAdditionalUserInfo *info = [result additionalUserInfo];
215-
FIRAuthCredential *c = [result credential];
213+
__unused FIRUser *u = [result user];
214+
__unused FIRAdditionalUserInfo *info = [result additionalUserInfo];
215+
__unused FIRAuthCredential *c = [result credential];
216216
}
217217

218218
- (void)FIRAuthErrors_h {
@@ -319,10 +319,10 @@ - (void)authTokenResult:(FIRAuthTokenResult *)result {
319319
d = [result issuedAtDate];
320320
s = [result signInProvider];
321321
s = [result signInSecondFactor];
322-
NSDictionary<NSString *, NSObject *> *dict = [result claims];
322+
__unused NSDictionary<NSString *, NSObject *> *dict = [result claims];
323323
}
324324

325-
#if !TARGET_OS_MACOS && !TARGET_OS_WATCHOS
325+
#if !TARGET_OS_OSX && !TARGET_OS_WATCH
326326
- (void)authTokenResult {
327327
AuthUIImpl *impl = [[AuthUIImpl alloc] init];
328328
[impl presentViewController:[[UIViewController alloc] init]
@@ -341,7 +341,7 @@ - (void)FIREmailAuthProvider_h {
341341
}
342342

343343
- (void)FIRFacebookAuthProvider_h {
344-
FIRAuthCredential *c = [FIRFacebookAuthProvider credentialWithAccessToken:@"token"];
344+
__unused FIRAuthCredential *c = [FIRFacebookAuthProvider credentialWithAccessToken:@"token"];
345345
}
346346

347347
#if TARGET_OS_IOS
@@ -353,7 +353,7 @@ - (void)FIRFederatedAuthProvider_h {
353353
}
354354
#endif
355355

356-
#if !TARGET_OS_WATCHOS
356+
#if !TARGET_OS_WATCH
357357
- (void)FIRGameCenterAuthProvider_h {
358358
[FIRGameCenterAuthProvider getCredentialWithCompletion:^(FIRAuthCredential *_Nullable credential,
359359
NSError *_Nullable error){
@@ -362,11 +362,11 @@ - (void)FIRGameCenterAuthProvider_h {
362362
#endif
363363

364364
- (void)FIRGitHubAuthProvider_h {
365-
FIRAuthCredential *c = [FIRGitHubAuthProvider credentialWithToken:@"token"];
365+
__unused FIRAuthCredential *c = [FIRGitHubAuthProvider credentialWithToken:@"token"];
366366
}
367367

368368
- (void)FIRGoogleAuthProvider_h {
369-
FIRAuthCredential *c = [FIRGoogleAuthProvider credentialWithIDToken:@"token"
369+
__unused FIRAuthCredential *c = [FIRGoogleAuthProvider credentialWithIDToken:@"token"
370370
accessToken:@"token"];
371371
}
372372

@@ -389,20 +389,20 @@ - (void)FIRMultiFactor_h:(FIRMultiFactor *)mf mfa:(FIRMultiFactorAssertion *)mfa
389389
}
390390

391391
- (void)multiFactorAssertion:(FIRMultiFactorAssertion *)mfa {
392-
NSString *s = [mfa factorID];
392+
__unused NSString *s = [mfa factorID];
393393
}
394394

395395
- (void)multiFactorInfo:(FIRMultiFactorInfo *)mfi {
396396
NSString *s = [mfi UID];
397397
s = [mfi factorID];
398398
s = [mfi displayName];
399-
NSDate *d = [mfi enrollmentDate];
399+
__unused NSDate *d = [mfi enrollmentDate];
400400
}
401401

402402
- (void)multiFactorResolver:(FIRMultiFactorResolver *)mfr {
403-
FIRMultiFactorSession *s = [mfr session];
404-
NSArray<FIRMultiFactorInfo *> *hints = [mfr hints];
405-
FIRAuth *auth = [mfr auth];
403+
__unused FIRMultiFactorSession *s = [mfr session];
404+
__unused NSArray<FIRMultiFactorInfo *> *hints = [mfr hints];
405+
__unused FIRAuth *auth = [mfr auth];
406406
}
407407
#endif
408408

@@ -428,9 +428,9 @@ - (void)FIROAuthProvider_h:(FIROAuthProvider *)provider {
428428
completion:^(FIRAuthCredential *_Nullable credential,
429429
NSError *_Nullable error){
430430
}];
431-
NSString *s = [provider providerID];
432-
NSArray<NSString *> *scopes = [provider scopes];
433-
NSDictionary<NSString *, NSString *> *params = [provider customParameters];
431+
__unused NSString *s = [provider providerID];
432+
__unused NSArray<NSString *> *scopes = [provider scopes];
433+
__unused NSDictionary<NSString *, NSString *> *params = [provider customParameters];
434434
}
435435

436436
- (void)FIRPhoneAuthProvider_h:(FIRPhoneAuthProvider *)provider mfi:(FIRPhoneMultiFactorInfo *)mfi {
@@ -449,7 +449,7 @@ - (void)FIRPhoneAuthProvider_h:(FIRPhoneAuthProvider *)provider mfi:(FIRPhoneMul
449449
completion:^(NSString *_Nullable verificationID,
450450
NSError *_Nullable error){
451451
}];
452-
FIRPhoneAuthCredential *c = [provider credentialWithVerificationID:@"id"
452+
__unused FIRPhoneAuthCredential *c = [provider credentialWithVerificationID:@"id"
453453
verificationCode:@"code"];
454454
}
455455

@@ -458,7 +458,7 @@ - (void)FIRPhoneAuthProvider_h:(FIRPhoneAuthCredential *)credential {
458458
}
459459

460460
- (void)phoneMultiFactorInfo:(FIRPhoneMultiFactorInfo *)info {
461-
NSString *s = [info phoneNumber];
461+
__unused NSString *s = [info phoneNumber];
462462
}
463463

464464
- (void)FIRTOTPSecret_h:(FIRTOTPSecret *)secret {
@@ -480,7 +480,7 @@ - (void)FIRTOTPMultiFactorGenerator_h:(FIRMultiFactorSession *)session
480480
#endif
481481

482482
- (void)FIRTwitterAuthProvider_h {
483-
FIRAuthCredential *c = [FIRTwitterAuthProvider credentialWithToken:@"token" secret:@"secret"];
483+
__unused FIRAuthCredential *c = [FIRTwitterAuthProvider credentialWithToken:@"token" secret:@"secret"];
484484
}
485485

486486
- (void)FIRUser_h:(FIRUser *)user credential:(FIRAuthCredential *)credential {
@@ -564,10 +564,10 @@ - (void)FIRUser_h:(FIRUser *)user credential:(FIRAuthCredential *)credential {
564564
- (void)userProperties:(FIRUser *)user {
565565
BOOL b = [user isAnonymous];
566566
b = [user isEmailVerified];
567-
NSArray<NSObject<FIRUserInfo> *> *userInfo = [user providerData];
568-
FIRUserMetadata *meta = [user metadata];
567+
__unused NSArray<NSObject<FIRUserInfo> *> *userInfo = [user providerData];
568+
__unused FIRUserMetadata *meta = [user metadata];
569569
#if TARGET_OS_IOS
570-
FIRMultiFactor *mf = [user multiFactor];
570+
__unused FIRMultiFactor *mf = [user multiFactor];
571571
#endif
572572
NSString *s = [user refreshToken];
573573
s = [user tenantID];
@@ -585,7 +585,7 @@ - (void)userInfoProperties:(NSObject<FIRUserInfo> *)userInfo {
585585
s = [userInfo displayName];
586586
s = [userInfo email];
587587
s = [userInfo phoneNumber];
588-
NSURL *u = [userInfo photoURL];
588+
__unused NSURL *u = [userInfo photoURL];
589589
}
590590

591591
- (void)userMetadataProperties:(FIRUserMetadata *)metadata {

0 commit comments

Comments
 (0)