@react-native-firebase/installations 26.3.3 → 27.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/RNFBInstallations.podspec +3 -1
- package/dist/module/version.js +1 -1
- package/dist/typescript/lib/index.d.ts +1 -1
- package/dist/typescript/lib/version.d.ts +1 -1
- package/ios/RNFBInstallations/RNFBInstallationsHelper.h +44 -0
- package/ios/RNFBInstallations/RNFBInstallationsHelper.m +117 -0
- package/ios/RNFBInstallations/RNFBInstallationsModule.mm +12 -80
- package/ios/RNFBInstallations.xcodeproj/project.pbxproj +6 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/Firebase/FIRInstallationsHostStub.m +122 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/Firebase/Firebase.h +42 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/RNFBApp/RCTConvert+FIRApp.h +13 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/RNFBApp/RCTConvert+FIRAppHostStub.m +27 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/RNFBApp/RNFBSharedUtils.h +18 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/RNFBApp/RNFBSharedUtilsHostStub.m +18 -0
- package/ios/RNFBInstallationsUnitTests/HostStubs/React/RCTBridgeModule.h +10 -0
- package/ios/RNFBInstallationsUnitTests/RNFBInstallationsHelperHostStubTests.m +233 -0
- package/ios/RNFBInstallationsUnitTests/RNFBInstallationsUnitTests.xcodeproj/project.pbxproj +255 -0
- package/ios/RNFBInstallationsUnitTests/RNFBInstallationsUnitTests.xcodeproj/xcshareddata/xcschemes/RNFBInstallationsUnitTests.xcscheme +69 -0
- package/lib/version.ts +1 -1
- package/package.json +5 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [27.0.0](https://github.com/invertase/react-native-firebase/compare/v26.4.0...v27.0.0) (2026-10-19)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @react-native-firebase/installations
|
|
9
|
+
|
|
10
|
+
## [26.4.0](https://github.com/invertase/react-native-firebase/compare/v26.3.3...v26.4.0) (2026-09-05)
|
|
11
|
+
|
|
12
|
+
**Note:** Version bump only for package @react-native-firebase/installations
|
|
13
|
+
|
|
6
14
|
## [26.3.3](https://github.com/invertase/react-native-firebase/compare/v26.3.2...v26.3.3) (2026-09-01)
|
|
7
15
|
|
|
8
16
|
### Reverts
|
|
@@ -31,7 +31,9 @@ Pod::Spec.new do |s|
|
|
|
31
31
|
s.tvos.deployment_target = firebase_tvos_target
|
|
32
32
|
s.source_files = 'ios/**/*.{h,m,mm,cpp,swift}'
|
|
33
33
|
s.private_header_files = "ios/**/*.h"
|
|
34
|
-
|
|
34
|
+
# CocoaPods FileList uses FNM_PATHNAME: `ios/*UnitTests/**` does not match nested
|
|
35
|
+
# files under HostStubs; use `ios/*UnitTests/**/*` (same as sibling packages).
|
|
36
|
+
s.exclude_files = 'ios/generated/RCTThirdPartyComponentsProvider.*', 'ios/generated/RCTAppDependencyProvider.*', 'ios/generated/RCTModuleProviders.*', 'ios/generated/RCTModulesConformingToProtocolsProvider.*', 'ios/generated/RCTUnstableModulesRequiringMainQueueSetupProvider.*', 'ios/*UnitTests/**/*'
|
|
35
37
|
|
|
36
38
|
# Must be set before install_modules_dependencies so RN can append use_frameworks
|
|
37
39
|
# HEADER_SEARCH_PATHS (React-debug etc.). Assigning after overwrites those paths
|
package/dist/module/version.js
CHANGED
|
@@ -6,7 +6,7 @@ import type { IdChangeCallbackFn, IdChangeUnsubscribeFn, Installations } from '.
|
|
|
6
6
|
*
|
|
7
7
|
* The firebase-js-sdk does not export `SDK_VERSION` from `@firebase/installations`.
|
|
8
8
|
*/
|
|
9
|
-
export declare const SDK_VERSION = "
|
|
9
|
+
export declare const SDK_VERSION = "27.0.0";
|
|
10
10
|
/**
|
|
11
11
|
* Returns the {@link Installations} instance for the default or given {@link FirebaseApp}.
|
|
12
12
|
*
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "
|
|
1
|
+
export declare const version = "27.0.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
#import <Foundation/Foundation.h>
|
|
19
|
+
#import <React/RCTBridgeModule.h>
|
|
20
|
+
|
|
21
|
+
// Plain Objective-C helper (see docs/ios-spm.mdx and
|
|
22
|
+
// okf-bundle/ios-spm-native-imports.md) that owns every call touching
|
|
23
|
+
// `FIRInstallations` for RNFBInstallationsModule. This keeps
|
|
24
|
+
// RNFBInstallationsModule.mm free of Firebase Installations imports: under SPM
|
|
25
|
+
// the CocoaPods umbrella is absent and the dual-import fallback uses `@import`,
|
|
26
|
+
// which cannot be used from an Objective-C++ (.mm) TurboModule when C++ modules
|
|
27
|
+
// are disabled (required by React Native's JSI headers). Installations still
|
|
28
|
+
// publishes Objective-C headers; the `.mm` must not `@import` them.
|
|
29
|
+
@interface RNFBInstallationsHelper : NSObject
|
|
30
|
+
|
|
31
|
+
+ (void)deleteInstallations:(NSString *)appName
|
|
32
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
33
|
+
reject:(RCTPromiseRejectBlock)reject;
|
|
34
|
+
|
|
35
|
+
+ (void)getId:(NSString *)appName
|
|
36
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
37
|
+
reject:(RCTPromiseRejectBlock)reject;
|
|
38
|
+
|
|
39
|
+
+ (void)getToken:(NSString *)appName
|
|
40
|
+
forceRefresh:(BOOL)forceRefresh
|
|
41
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
42
|
+
reject:(RCTPromiseRejectBlock)reject;
|
|
43
|
+
|
|
44
|
+
@end
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
#if __has_include(<Firebase/Firebase.h>)
|
|
19
|
+
#import <Firebase/Firebase.h>
|
|
20
|
+
#elif __has_include(<FirebaseInstallations/FirebaseInstallations.h>)
|
|
21
|
+
#import <FirebaseCore/FirebaseCore.h>
|
|
22
|
+
#import <FirebaseInstallations/FirebaseInstallations.h>
|
|
23
|
+
#else
|
|
24
|
+
@import FirebaseCore;
|
|
25
|
+
@import FirebaseInstallations;
|
|
26
|
+
#endif
|
|
27
|
+
|
|
28
|
+
#import "RNFBApp/RCTConvert+FIRApp.h"
|
|
29
|
+
#import "RNFBApp/RNFBSharedUtils.h"
|
|
30
|
+
#import "RNFBInstallationsHelper.h"
|
|
31
|
+
|
|
32
|
+
@implementation RNFBInstallationsHelper
|
|
33
|
+
|
|
34
|
+
+ (void)deleteInstallations:(NSString *)appName
|
|
35
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
36
|
+
reject:(RCTPromiseRejectBlock)reject {
|
|
37
|
+
FIRApp *firebaseApp = [RCTConvert firAppFromString:appName];
|
|
38
|
+
FIRInstallations *installations = [FIRInstallations installationsWithApp:firebaseApp];
|
|
39
|
+
[installations deleteWithCompletion:^(NSError *_Nullable error) {
|
|
40
|
+
if (error != nil) {
|
|
41
|
+
DLog(@"Unable to delete Installations ID: %@", error);
|
|
42
|
+
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
43
|
+
userInfo:(NSMutableDictionary *)@{
|
|
44
|
+
@"code" : @"delete-error",
|
|
45
|
+
@"message" : [error localizedDescription],
|
|
46
|
+
}];
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
resolve([NSNull null]);
|
|
51
|
+
}];
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
+ (void)getId:(NSString *)appName
|
|
55
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
56
|
+
reject:(RCTPromiseRejectBlock)reject {
|
|
57
|
+
FIRApp *firebaseApp = [RCTConvert firAppFromString:appName];
|
|
58
|
+
FIRInstallations *installations = [FIRInstallations installationsWithApp:firebaseApp];
|
|
59
|
+
[installations installationIDWithCompletion:^(NSString *_Nullable id, NSError *_Nullable error) {
|
|
60
|
+
if (error != nil) {
|
|
61
|
+
DLog(@"Unable to retrieve Installations ID: %@", error);
|
|
62
|
+
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
63
|
+
userInfo:(NSMutableDictionary *)@{
|
|
64
|
+
@"code" : @"id-error",
|
|
65
|
+
@"message" : [error localizedDescription],
|
|
66
|
+
}];
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
if (id == nil) {
|
|
70
|
+
DLog(@"Unable to retrieve Installations ID.");
|
|
71
|
+
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
72
|
+
userInfo:(NSMutableDictionary *)@{
|
|
73
|
+
@"code" : @"id-null",
|
|
74
|
+
@"message" : @"no id fetched",
|
|
75
|
+
}];
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
resolve(id);
|
|
80
|
+
}];
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
+ (void)getToken:(NSString *)appName
|
|
84
|
+
forceRefresh:(BOOL)forceRefresh
|
|
85
|
+
resolve:(RCTPromiseResolveBlock)resolve
|
|
86
|
+
reject:(RCTPromiseRejectBlock)reject {
|
|
87
|
+
FIRApp *firebaseApp = [RCTConvert firAppFromString:appName];
|
|
88
|
+
FIRInstallations *installations = [FIRInstallations installationsWithApp:firebaseApp];
|
|
89
|
+
[installations authTokenForcingRefresh:forceRefresh
|
|
90
|
+
completion:^(FIRInstallationsAuthTokenResult *_Nullable token,
|
|
91
|
+
NSError *_Nullable error) {
|
|
92
|
+
if (error != nil) {
|
|
93
|
+
DLog(@"Unable to retrieve Installations auth token: %@", error);
|
|
94
|
+
[RNFBSharedUtils
|
|
95
|
+
rejectPromiseWithUserInfo:reject
|
|
96
|
+
userInfo:(NSMutableDictionary *)@{
|
|
97
|
+
@"code" : @"token-error",
|
|
98
|
+
@"message" : [error localizedDescription],
|
|
99
|
+
}];
|
|
100
|
+
return;
|
|
101
|
+
}
|
|
102
|
+
if (token == nil) {
|
|
103
|
+
DLog(@"Unable to retrieve Installations auth token.");
|
|
104
|
+
[RNFBSharedUtils
|
|
105
|
+
rejectPromiseWithUserInfo:reject
|
|
106
|
+
userInfo:(NSMutableDictionary *)@{
|
|
107
|
+
@"code" : @"token-null",
|
|
108
|
+
@"message" : @"no token fetched",
|
|
109
|
+
}];
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
resolve(token.authToken);
|
|
114
|
+
}];
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
@end
|
|
@@ -15,20 +15,13 @@
|
|
|
15
15
|
*
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
#else
|
|
24
|
-
@import FirebaseCore;
|
|
25
|
-
@import FirebaseInstallations;
|
|
26
|
-
#endif
|
|
27
|
-
#import <React/RCTUtils.h>
|
|
28
|
-
|
|
29
|
-
#import "RNFBApp/RCTConvert+FIRApp.h"
|
|
30
|
-
#import "RNFBApp/RNFBSharedUtils.h"
|
|
18
|
+
// This module intentionally has no Firebase imports — see RNFBInstallationsHelper.h /
|
|
19
|
+
// okf-bundle/ios-spm-native-imports.md. Every Firebase Installations SDK call is routed
|
|
20
|
+
// through the plain Objective-C RNFBInstallationsHelper class instead, which can safely
|
|
21
|
+
// use the CocoaPods/SPM dual-import (including `@import`) because it compiles as ObjC,
|
|
22
|
+
// not ObjC++.
|
|
31
23
|
#import "RNFBInstallationsModule.h"
|
|
24
|
+
#import "RNFBInstallationsHelper.h"
|
|
32
25
|
|
|
33
26
|
@implementation RNFBInstallationsModule
|
|
34
27
|
|
|
@@ -49,84 +42,23 @@ RCT_EXPORT_MODULE(NativeRNFBTurboInstallations)
|
|
|
49
42
|
- (void)deleteInstallations:(NSString *)appName
|
|
50
43
|
resolve:(RCTPromiseResolveBlock)resolve
|
|
51
44
|
reject:(RCTPromiseRejectBlock)reject {
|
|
52
|
-
|
|
53
|
-
FIRInstallations *installations = [FIRInstallations installationsWithApp:firebaseApp];
|
|
54
|
-
[installations deleteWithCompletion:^(NSError *_Nullable error) {
|
|
55
|
-
if (error != nil) {
|
|
56
|
-
DLog(@"Unable to delete Installations ID: %@", error);
|
|
57
|
-
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
58
|
-
userInfo:(NSMutableDictionary *)@{
|
|
59
|
-
@"code" : @"delete-error",
|
|
60
|
-
@"message" : [error localizedDescription],
|
|
61
|
-
}];
|
|
62
|
-
return;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
resolve([NSNull null]);
|
|
66
|
-
}];
|
|
45
|
+
[RNFBInstallationsHelper deleteInstallations:appName resolve:resolve reject:reject];
|
|
67
46
|
}
|
|
68
47
|
|
|
69
48
|
- (void)getId:(NSString *)appName
|
|
70
49
|
resolve:(RCTPromiseResolveBlock)resolve
|
|
71
50
|
reject:(RCTPromiseRejectBlock)reject {
|
|
72
|
-
|
|
73
|
-
FIRInstallations *installations = [FIRInstallations installationsWithApp:firebaseApp];
|
|
74
|
-
[installations installationIDWithCompletion:^(NSString *_Nullable id, NSError *_Nullable error) {
|
|
75
|
-
if (error != nil) {
|
|
76
|
-
DLog(@"Unable to retrieve Installations ID: %@", error);
|
|
77
|
-
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
78
|
-
userInfo:(NSMutableDictionary *)@{
|
|
79
|
-
@"code" : @"id-error",
|
|
80
|
-
@"message" : [error localizedDescription],
|
|
81
|
-
}];
|
|
82
|
-
return;
|
|
83
|
-
}
|
|
84
|
-
if (id == nil) {
|
|
85
|
-
DLog(@"Unable to retrieve Installations ID.");
|
|
86
|
-
[RNFBSharedUtils rejectPromiseWithUserInfo:reject
|
|
87
|
-
userInfo:(NSMutableDictionary *)@{
|
|
88
|
-
@"code" : @"id-null",
|
|
89
|
-
@"message" : @"no id fetched",
|
|
90
|
-
}];
|
|
91
|
-
return;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
resolve(id);
|
|
95
|
-
}];
|
|
51
|
+
[RNFBInstallationsHelper getId:appName resolve:resolve reject:reject];
|
|
96
52
|
}
|
|
97
53
|
|
|
98
54
|
- (void)getToken:(NSString *)appName
|
|
99
55
|
forceRefresh:(BOOL)forceRefresh
|
|
100
56
|
resolve:(RCTPromiseResolveBlock)resolve
|
|
101
57
|
reject:(RCTPromiseRejectBlock)reject {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
NSError *_Nullable error) {
|
|
107
|
-
if (error != nil) {
|
|
108
|
-
DLog(@"Unable to retrieve Installations auth token: %@", error);
|
|
109
|
-
[RNFBSharedUtils
|
|
110
|
-
rejectPromiseWithUserInfo:reject
|
|
111
|
-
userInfo:(NSMutableDictionary *)@{
|
|
112
|
-
@"code" : @"token-error",
|
|
113
|
-
@"message" : [error localizedDescription],
|
|
114
|
-
}];
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
if (token == nil) {
|
|
118
|
-
DLog(@"Unable to retrieve Installations auth token.");
|
|
119
|
-
[RNFBSharedUtils
|
|
120
|
-
rejectPromiseWithUserInfo:reject
|
|
121
|
-
userInfo:(NSMutableDictionary *)@{
|
|
122
|
-
@"code" : @"token-null",
|
|
123
|
-
@"message" : @"no token fetched",
|
|
124
|
-
}];
|
|
125
|
-
return;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
resolve(token.authToken);
|
|
129
|
-
}];
|
|
58
|
+
[RNFBInstallationsHelper getToken:appName
|
|
59
|
+
forceRefresh:forceRefresh
|
|
60
|
+
resolve:resolve
|
|
61
|
+
reject:reject];
|
|
130
62
|
}
|
|
131
63
|
|
|
132
64
|
@end
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
/* Begin PBXBuildFile section */
|
|
10
10
|
2744B98621F45429004F8E3F /* RNFBInstallationsModule.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2744B98521F45429004F8E3F /* RNFBInstallationsModule.mm */; };
|
|
11
|
+
RNFBIN000000000000000003 /* RNFBInstallationsHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = RNFBIN000000000000000005 /* RNFBInstallationsHelper.m */; };
|
|
11
12
|
/* End PBXBuildFile section */
|
|
12
13
|
|
|
13
14
|
/* Begin PBXCopyFilesBuildPhase section */
|
|
@@ -26,6 +27,8 @@
|
|
|
26
27
|
2744B98221F45429004F8E3F /* libRNFBInstallations.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRNFBInstallations.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
27
28
|
2744B98421F45429004F8E3F /* RNFBInstallationsModule.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = RNFBInstallationsModule.h; path = RNFBInstallations/RNFBInstallationsModule.h; sourceTree = SOURCE_ROOT; };
|
|
28
29
|
2744B98521F45429004F8E3F /* RNFBInstallationsModule.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = RNFBInstallationsModule.mm; path = RNFBInstallations/RNFBInstallationsModule.mm; sourceTree = SOURCE_ROOT; };
|
|
30
|
+
RNFBIN000000000000000004 /* RNFBInstallationsHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = RNFBInstallationsHelper.h; path = RNFBInstallations/RNFBInstallationsHelper.h; sourceTree = SOURCE_ROOT; };
|
|
31
|
+
RNFBIN000000000000000005 /* RNFBInstallationsHelper.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = RNFBInstallationsHelper.m; path = RNFBInstallations/RNFBInstallationsHelper.m; sourceTree = SOURCE_ROOT; };
|
|
29
32
|
/* End PBXFileReference section */
|
|
30
33
|
|
|
31
34
|
/* Begin PBXFrameworksBuildPhase section */
|
|
@@ -54,6 +57,8 @@
|
|
|
54
57
|
2744B98C21F45C64004F8E3F /* common */,
|
|
55
58
|
2744B98421F45429004F8E3F /* RNFBInstallationsModule.h */,
|
|
56
59
|
2744B98521F45429004F8E3F /* RNFBInstallationsModule.mm */,
|
|
60
|
+
RNFBIN000000000000000004 /* RNFBInstallationsHelper.h */,
|
|
61
|
+
RNFBIN000000000000000005 /* RNFBInstallationsHelper.m */,
|
|
57
62
|
);
|
|
58
63
|
path = RNFBInstallations;
|
|
59
64
|
sourceTree = "<group>";
|
|
@@ -125,6 +130,7 @@
|
|
|
125
130
|
buildActionMask = 2147483647;
|
|
126
131
|
files = (
|
|
127
132
|
2744B98621F45429004F8E3F /* RNFBInstallationsModule.mm in Sources */,
|
|
133
|
+
RNFBIN000000000000000003 /* RNFBInstallationsHelper.m in Sources */,
|
|
128
134
|
);
|
|
129
135
|
runOnlyForDeploymentPostprocessing = 0;
|
|
130
136
|
};
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import <Firebase/Firebase.h>
|
|
5
|
+
|
|
6
|
+
@implementation FIRApp
|
|
7
|
+
|
|
8
|
+
- (instancetype)initWithName:(NSString *)name {
|
|
9
|
+
self = [super init];
|
|
10
|
+
if (self) {
|
|
11
|
+
_name = [name copy];
|
|
12
|
+
}
|
|
13
|
+
return self;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
@end
|
|
17
|
+
|
|
18
|
+
@implementation FIRInstallationsAuthTokenResult {
|
|
19
|
+
NSString *_authToken;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
- (instancetype)initWithAuthToken:(NSString *)authToken {
|
|
23
|
+
self = [super init];
|
|
24
|
+
if (self) {
|
|
25
|
+
_authToken = [authToken copy];
|
|
26
|
+
}
|
|
27
|
+
return self;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
- (NSString *)authToken {
|
|
31
|
+
return _authToken;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@end
|
|
35
|
+
|
|
36
|
+
@implementation FIRInstallations
|
|
37
|
+
|
|
38
|
+
static void (^sDeleteHandler)(FIRInstallationsDeleteCompletion);
|
|
39
|
+
static void (^sInstallationIDHandler)(FIRInstallationsIDHandler);
|
|
40
|
+
static void (^sAuthTokenHandler)(BOOL, FIRInstallationsTokenHandler);
|
|
41
|
+
static NSMutableDictionary<NSString *, FIRInstallations *> *sInstances;
|
|
42
|
+
|
|
43
|
+
+ (void)initialize {
|
|
44
|
+
if (self == [FIRInstallations class]) {
|
|
45
|
+
sInstances = [NSMutableDictionary new];
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
+ (void (^)(FIRInstallationsDeleteCompletion))deleteHandler {
|
|
50
|
+
return sDeleteHandler;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
+ (void)setDeleteHandler:(void (^)(FIRInstallationsDeleteCompletion))deleteHandler {
|
|
54
|
+
sDeleteHandler = [deleteHandler copy];
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
+ (void (^)(FIRInstallationsIDHandler))installationIDHandler {
|
|
58
|
+
return sInstallationIDHandler;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
+ (void)setInstallationIDHandler:(void (^)(FIRInstallationsIDHandler))installationIDHandler {
|
|
62
|
+
sInstallationIDHandler = [installationIDHandler copy];
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
+ (void (^)(BOOL, FIRInstallationsTokenHandler))authTokenHandler {
|
|
66
|
+
return sAuthTokenHandler;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
+ (void)setAuthTokenHandler:(void (^)(BOOL, FIRInstallationsTokenHandler))authTokenHandler {
|
|
70
|
+
sAuthTokenHandler = [authTokenHandler copy];
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
+ (void)resetTestState {
|
|
74
|
+
sDeleteHandler = nil;
|
|
75
|
+
sInstallationIDHandler = nil;
|
|
76
|
+
sAuthTokenHandler = nil;
|
|
77
|
+
[sInstances removeAllObjects];
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
+ (instancetype)installationsWithApp:(FIRApp *)app {
|
|
81
|
+
NSString *key = app.name ?: @"__nil__";
|
|
82
|
+
FIRInstallations *existing = sInstances[key];
|
|
83
|
+
if (existing != nil) {
|
|
84
|
+
return existing;
|
|
85
|
+
}
|
|
86
|
+
FIRInstallations *created = [[FIRInstallations alloc] init];
|
|
87
|
+
sInstances[key] = created;
|
|
88
|
+
return created;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
- (void)deleteWithCompletion:(FIRInstallationsDeleteCompletion)completion {
|
|
92
|
+
if (sDeleteHandler != nil) {
|
|
93
|
+
sDeleteHandler(completion);
|
|
94
|
+
return;
|
|
95
|
+
}
|
|
96
|
+
if (completion != nil) {
|
|
97
|
+
completion(nil);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
- (void)installationIDWithCompletion:(FIRInstallationsIDHandler)completion {
|
|
102
|
+
if (sInstallationIDHandler != nil) {
|
|
103
|
+
sInstallationIDHandler(completion);
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
if (completion != nil) {
|
|
107
|
+
completion(@"stub-installation-id", nil);
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
- (void)authTokenForcingRefresh:(BOOL)forceRefresh
|
|
112
|
+
completion:(FIRInstallationsTokenHandler)completion {
|
|
113
|
+
if (sAuthTokenHandler != nil) {
|
|
114
|
+
sAuthTokenHandler(forceRefresh, completion);
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
if (completion != nil) {
|
|
118
|
+
completion([[FIRInstallationsAuthTokenResult alloc] initWithAuthToken:@"stub-auth-token"], nil);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
@end
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
* Enough of Firebase Core / Installations for compiling RNFBInstallationsHelper.m
|
|
4
|
+
* and driving completion branches without linking the SDK.
|
|
5
|
+
*/
|
|
6
|
+
#import <Foundation/Foundation.h>
|
|
7
|
+
|
|
8
|
+
@interface FIRApp : NSObject
|
|
9
|
+
@property(nonatomic, copy) NSString *name;
|
|
10
|
+
- (instancetype)initWithName:(NSString *)name;
|
|
11
|
+
@end
|
|
12
|
+
|
|
13
|
+
@interface FIRInstallationsAuthTokenResult : NSObject
|
|
14
|
+
@property(nonatomic, readonly, copy) NSString *authToken;
|
|
15
|
+
- (instancetype)initWithAuthToken:(NSString *)authToken;
|
|
16
|
+
@end
|
|
17
|
+
|
|
18
|
+
typedef void (^FIRInstallationsDeleteCompletion)(NSError *_Nullable error);
|
|
19
|
+
typedef void (^FIRInstallationsIDHandler)(NSString *_Nullable identifier, NSError *_Nullable error);
|
|
20
|
+
typedef void (^FIRInstallationsTokenHandler)(FIRInstallationsAuthTokenResult *_Nullable token,
|
|
21
|
+
NSError *_Nullable error);
|
|
22
|
+
|
|
23
|
+
@interface FIRInstallations : NSObject
|
|
24
|
+
|
|
25
|
+
+ (instancetype)installationsWithApp:(FIRApp *)app;
|
|
26
|
+
|
|
27
|
+
- (void)deleteWithCompletion:(FIRInstallationsDeleteCompletion)completion;
|
|
28
|
+
- (void)installationIDWithCompletion:(FIRInstallationsIDHandler)completion;
|
|
29
|
+
- (void)authTokenForcingRefresh:(BOOL)forceRefresh
|
|
30
|
+
completion:(FIRInstallationsTokenHandler)completion;
|
|
31
|
+
|
|
32
|
+
/** Test seams: when set, invoked instead of a network/SDK fetch. */
|
|
33
|
+
@property(class, nonatomic, copy, nullable) void (^deleteHandler)
|
|
34
|
+
(FIRInstallationsDeleteCompletion completion);
|
|
35
|
+
@property(class, nonatomic, copy, nullable) void (^installationIDHandler)
|
|
36
|
+
(FIRInstallationsIDHandler completion);
|
|
37
|
+
@property(class, nonatomic, copy, nullable) void (^authTokenHandler)
|
|
38
|
+
(BOOL forceRefresh, FIRInstallationsTokenHandler completion);
|
|
39
|
+
|
|
40
|
+
+ (void)resetTestState;
|
|
41
|
+
|
|
42
|
+
@end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import <Foundation/Foundation.h>
|
|
5
|
+
|
|
6
|
+
@class FIRApp;
|
|
7
|
+
|
|
8
|
+
@interface RCTConvert : NSObject
|
|
9
|
+
+ (FIRApp *)firAppFromString:(NSString *)appName;
|
|
10
|
+
/** Test seam: map appName → FIRApp. Cleared via resetTestState. */
|
|
11
|
+
+ (void)setFirAppFromStringHandler:(FIRApp * (^)(NSString *appName))handler;
|
|
12
|
+
+ (void)resetTestState;
|
|
13
|
+
@end
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import "RNFBApp/RCTConvert+FIRApp.h"
|
|
5
|
+
|
|
6
|
+
#import <Firebase/Firebase.h>
|
|
7
|
+
|
|
8
|
+
@implementation RCTConvert
|
|
9
|
+
|
|
10
|
+
static FIRApp * (^sFirAppFromStringHandler)(NSString *appName);
|
|
11
|
+
|
|
12
|
+
+ (FIRApp *)firAppFromString:(NSString *)appName {
|
|
13
|
+
if (sFirAppFromStringHandler != nil) {
|
|
14
|
+
return sFirAppFromStringHandler(appName);
|
|
15
|
+
}
|
|
16
|
+
return [[FIRApp alloc] initWithName:appName ?: @"[DEFAULT]"];
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
+ (void)setFirAppFromStringHandler:(FIRApp * (^)(NSString *appName))handler {
|
|
20
|
+
sFirAppFromStringHandler = [handler copy];
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
+ (void)resetTestState {
|
|
24
|
+
sFirAppFromStringHandler = nil;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
@end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import <Foundation/Foundation.h>
|
|
5
|
+
#import <React/RCTBridgeModule.h>
|
|
6
|
+
|
|
7
|
+
#ifdef DEBUG
|
|
8
|
+
#define DLog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__);
|
|
9
|
+
#else
|
|
10
|
+
#define DLog(...)
|
|
11
|
+
#endif
|
|
12
|
+
|
|
13
|
+
@interface RNFBSharedUtils : NSObject
|
|
14
|
+
|
|
15
|
+
+ (void)rejectPromiseWithUserInfo:(RCTPromiseRejectBlock)reject
|
|
16
|
+
userInfo:(NSMutableDictionary *)userInfo;
|
|
17
|
+
|
|
18
|
+
@end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import "RNFBApp/RNFBSharedUtils.h"
|
|
5
|
+
|
|
6
|
+
@implementation RNFBSharedUtils
|
|
7
|
+
|
|
8
|
+
+ (void)rejectPromiseWithUserInfo:(RCTPromiseRejectBlock)reject
|
|
9
|
+
userInfo:(NSMutableDictionary *)userInfo {
|
|
10
|
+
if (reject == nil) {
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
NSString *code = userInfo[@"code"] ?: @"unknown";
|
|
14
|
+
NSString *message = userInfo[@"message"] ?: @"";
|
|
15
|
+
reject(code, message, nil);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
@end
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Host-only stub for macOS XCTest. Not shipped in the production pod.
|
|
3
|
+
*/
|
|
4
|
+
#import <Foundation/Foundation.h>
|
|
5
|
+
|
|
6
|
+
typedef void (^RCTPromiseResolveBlock)(id result);
|
|
7
|
+
typedef void (^RCTPromiseRejectBlock)(NSString *code, NSString *message, NSError *error);
|
|
8
|
+
|
|
9
|
+
@protocol RCTBridgeModule <NSObject>
|
|
10
|
+
@end
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2016-present Invertase Limited & Contributors
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this library except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
#import <XCTest/XCTest.h>
|
|
18
|
+
|
|
19
|
+
#import <Firebase/Firebase.h>
|
|
20
|
+
#import "RNFBApp/RCTConvert+FIRApp.h"
|
|
21
|
+
#import "RNFBInstallationsHelper.h"
|
|
22
|
+
|
|
23
|
+
@interface RNFBInstallationsHelperHostStubTests : XCTestCase
|
|
24
|
+
@end
|
|
25
|
+
|
|
26
|
+
@implementation RNFBInstallationsHelperHostStubTests
|
|
27
|
+
|
|
28
|
+
- (void)setUp {
|
|
29
|
+
[super setUp];
|
|
30
|
+
[FIRInstallations resetTestState];
|
|
31
|
+
[RCTConvert resetTestState];
|
|
32
|
+
[RCTConvert setFirAppFromStringHandler:^FIRApp *(NSString *appName) {
|
|
33
|
+
return [[FIRApp alloc] initWithName:appName ?: @"[DEFAULT]"];
|
|
34
|
+
}];
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
- (void)tearDown {
|
|
38
|
+
[FIRInstallations resetTestState];
|
|
39
|
+
[RCTConvert resetTestState];
|
|
40
|
+
[super tearDown];
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
- (void)testDeleteInstallations_success_resolvesNull {
|
|
44
|
+
__block id resolved = @"unset";
|
|
45
|
+
__block BOOL rejected = NO;
|
|
46
|
+
|
|
47
|
+
[RNFBInstallationsHelper deleteInstallations:@"helper-delete-ok"
|
|
48
|
+
resolve:^(id result) {
|
|
49
|
+
resolved = result;
|
|
50
|
+
}
|
|
51
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
52
|
+
(void)code;
|
|
53
|
+
(void)message;
|
|
54
|
+
(void)error;
|
|
55
|
+
rejected = YES;
|
|
56
|
+
}];
|
|
57
|
+
|
|
58
|
+
XCTAssertFalse(rejected);
|
|
59
|
+
XCTAssertEqualObjects(resolved, [NSNull null]);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
- (void)testDeleteInstallations_error_rejectsDeleteError {
|
|
63
|
+
FIRInstallations.deleteHandler = ^(FIRInstallationsDeleteCompletion completion) {
|
|
64
|
+
completion([NSError errorWithDomain:@"io.invertase.firebase.installations.test"
|
|
65
|
+
code:1
|
|
66
|
+
userInfo:@{NSLocalizedDescriptionKey : @"delete failed"}]);
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
__block NSString *rejectCode = nil;
|
|
70
|
+
__block NSString *rejectMessage = nil;
|
|
71
|
+
[RNFBInstallationsHelper deleteInstallations:@"helper-delete-err"
|
|
72
|
+
resolve:^(id result) {
|
|
73
|
+
(void)result;
|
|
74
|
+
XCTFail(@"expected reject");
|
|
75
|
+
}
|
|
76
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
77
|
+
(void)error;
|
|
78
|
+
rejectCode = code;
|
|
79
|
+
rejectMessage = message;
|
|
80
|
+
}];
|
|
81
|
+
|
|
82
|
+
XCTAssertEqualObjects(rejectCode, @"delete-error");
|
|
83
|
+
XCTAssertEqualObjects(rejectMessage, @"delete failed");
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
- (void)testGetId_success_resolvesId {
|
|
87
|
+
FIRInstallations.installationIDHandler = ^(FIRInstallationsIDHandler completion) {
|
|
88
|
+
completion(@"installation-123", nil);
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
__block id resolved = @"unset";
|
|
92
|
+
__block BOOL rejected = NO;
|
|
93
|
+
[RNFBInstallationsHelper getId:@"helper-id-ok"
|
|
94
|
+
resolve:^(id result) {
|
|
95
|
+
resolved = result;
|
|
96
|
+
}
|
|
97
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
98
|
+
(void)code;
|
|
99
|
+
(void)message;
|
|
100
|
+
(void)error;
|
|
101
|
+
rejected = YES;
|
|
102
|
+
}];
|
|
103
|
+
|
|
104
|
+
XCTAssertFalse(rejected);
|
|
105
|
+
XCTAssertEqualObjects(resolved, @"installation-123");
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
- (void)testGetId_error_rejectsIdError {
|
|
109
|
+
FIRInstallations.installationIDHandler = ^(FIRInstallationsIDHandler completion) {
|
|
110
|
+
completion(nil, [NSError errorWithDomain:@"io.invertase.firebase.installations.test"
|
|
111
|
+
code:2
|
|
112
|
+
userInfo:@{NSLocalizedDescriptionKey : @"id failed"}]);
|
|
113
|
+
};
|
|
114
|
+
|
|
115
|
+
__block NSString *rejectCode = nil;
|
|
116
|
+
__block NSString *rejectMessage = nil;
|
|
117
|
+
[RNFBInstallationsHelper getId:@"helper-id-err"
|
|
118
|
+
resolve:^(id result) {
|
|
119
|
+
(void)result;
|
|
120
|
+
XCTFail(@"expected reject");
|
|
121
|
+
}
|
|
122
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
123
|
+
(void)error;
|
|
124
|
+
rejectCode = code;
|
|
125
|
+
rejectMessage = message;
|
|
126
|
+
}];
|
|
127
|
+
|
|
128
|
+
XCTAssertEqualObjects(rejectCode, @"id-error");
|
|
129
|
+
XCTAssertEqualObjects(rejectMessage, @"id failed");
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
- (void)testGetId_nilId_rejectsIdNull {
|
|
133
|
+
FIRInstallations.installationIDHandler = ^(FIRInstallationsIDHandler completion) {
|
|
134
|
+
completion(nil, nil);
|
|
135
|
+
};
|
|
136
|
+
|
|
137
|
+
__block NSString *rejectCode = nil;
|
|
138
|
+
__block NSString *rejectMessage = nil;
|
|
139
|
+
[RNFBInstallationsHelper getId:@"helper-id-nil"
|
|
140
|
+
resolve:^(id result) {
|
|
141
|
+
(void)result;
|
|
142
|
+
XCTFail(@"expected reject");
|
|
143
|
+
}
|
|
144
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
145
|
+
(void)error;
|
|
146
|
+
rejectCode = code;
|
|
147
|
+
rejectMessage = message;
|
|
148
|
+
}];
|
|
149
|
+
|
|
150
|
+
XCTAssertEqualObjects(rejectCode, @"id-null");
|
|
151
|
+
XCTAssertEqualObjects(rejectMessage, @"no id fetched");
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
- (void)testGetToken_success_resolvesAuthToken {
|
|
155
|
+
__block BOOL sawForceRefresh = NO;
|
|
156
|
+
FIRInstallations.authTokenHandler = ^(BOOL forceRefresh,
|
|
157
|
+
FIRInstallationsTokenHandler completion) {
|
|
158
|
+
sawForceRefresh = forceRefresh;
|
|
159
|
+
completion([[FIRInstallationsAuthTokenResult alloc] initWithAuthToken:@"auth-token-xyz"], nil);
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
__block id resolved = @"unset";
|
|
163
|
+
__block BOOL rejected = NO;
|
|
164
|
+
[RNFBInstallationsHelper getToken:@"helper-token-ok"
|
|
165
|
+
forceRefresh:YES
|
|
166
|
+
resolve:^(id result) {
|
|
167
|
+
resolved = result;
|
|
168
|
+
}
|
|
169
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
170
|
+
(void)code;
|
|
171
|
+
(void)message;
|
|
172
|
+
(void)error;
|
|
173
|
+
rejected = YES;
|
|
174
|
+
}];
|
|
175
|
+
|
|
176
|
+
XCTAssertFalse(rejected);
|
|
177
|
+
XCTAssertTrue(sawForceRefresh);
|
|
178
|
+
XCTAssertEqualObjects(resolved, @"auth-token-xyz");
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
- (void)testGetToken_error_rejectsTokenError {
|
|
182
|
+
FIRInstallations.authTokenHandler =
|
|
183
|
+
^(BOOL forceRefresh, FIRInstallationsTokenHandler completion) {
|
|
184
|
+
(void)forceRefresh;
|
|
185
|
+
completion(nil, [NSError errorWithDomain:@"io.invertase.firebase.installations.test"
|
|
186
|
+
code:3
|
|
187
|
+
userInfo:@{NSLocalizedDescriptionKey : @"token failed"}]);
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
__block NSString *rejectCode = nil;
|
|
191
|
+
__block NSString *rejectMessage = nil;
|
|
192
|
+
[RNFBInstallationsHelper getToken:@"helper-token-err"
|
|
193
|
+
forceRefresh:NO
|
|
194
|
+
resolve:^(id result) {
|
|
195
|
+
(void)result;
|
|
196
|
+
XCTFail(@"expected reject");
|
|
197
|
+
}
|
|
198
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
199
|
+
(void)error;
|
|
200
|
+
rejectCode = code;
|
|
201
|
+
rejectMessage = message;
|
|
202
|
+
}];
|
|
203
|
+
|
|
204
|
+
XCTAssertEqualObjects(rejectCode, @"token-error");
|
|
205
|
+
XCTAssertEqualObjects(rejectMessage, @"token failed");
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
- (void)testGetToken_nilToken_rejectsTokenNull {
|
|
209
|
+
FIRInstallations.authTokenHandler =
|
|
210
|
+
^(BOOL forceRefresh, FIRInstallationsTokenHandler completion) {
|
|
211
|
+
(void)forceRefresh;
|
|
212
|
+
completion(nil, nil);
|
|
213
|
+
};
|
|
214
|
+
|
|
215
|
+
__block NSString *rejectCode = nil;
|
|
216
|
+
__block NSString *rejectMessage = nil;
|
|
217
|
+
[RNFBInstallationsHelper getToken:@"helper-token-nil"
|
|
218
|
+
forceRefresh:NO
|
|
219
|
+
resolve:^(id result) {
|
|
220
|
+
(void)result;
|
|
221
|
+
XCTFail(@"expected reject");
|
|
222
|
+
}
|
|
223
|
+
reject:^(NSString *code, NSString *message, NSError *error) {
|
|
224
|
+
(void)error;
|
|
225
|
+
rejectCode = code;
|
|
226
|
+
rejectMessage = message;
|
|
227
|
+
}];
|
|
228
|
+
|
|
229
|
+
XCTAssertEqualObjects(rejectCode, @"token-null");
|
|
230
|
+
XCTAssertEqualObjects(rejectMessage, @"no token fetched");
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
@end
|
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
// !$*UTF8*$!
|
|
2
|
+
{
|
|
3
|
+
archiveVersion = 1;
|
|
4
|
+
classes = {
|
|
5
|
+
};
|
|
6
|
+
objectVersion = 56;
|
|
7
|
+
objects = {
|
|
8
|
+
|
|
9
|
+
/* Begin PBXBuildFile section */
|
|
10
|
+
IN1000000000000000000015 /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000014 /* XCTest.framework */; };
|
|
11
|
+
IN1000000000000000000020 /* RNFBInstallationsHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000021 /* RNFBInstallationsHelper.m */; };
|
|
12
|
+
IN1000000000000000000022 /* RNFBInstallationsHelperHostStubTests.m in Sources */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000023 /* RNFBInstallationsHelperHostStubTests.m */; };
|
|
13
|
+
IN1000000000000000000024 /* FIRInstallationsHostStub.m in Sources */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000025 /* FIRInstallationsHostStub.m */; };
|
|
14
|
+
IN1000000000000000000026 /* RNFBSharedUtilsHostStub.m in Sources */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000027 /* RNFBSharedUtilsHostStub.m */; };
|
|
15
|
+
IN1000000000000000000028 /* RCTConvert+FIRAppHostStub.m in Sources */ = {isa = PBXBuildFile; fileRef = IN1000000000000000000029 /* RCTConvert+FIRAppHostStub.m */; };
|
|
16
|
+
/* End PBXBuildFile section */
|
|
17
|
+
|
|
18
|
+
/* Begin PBXFileReference section */
|
|
19
|
+
IN1000000000000000000003 /* RNFBInstallationsUnitTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = RNFBInstallationsUnitTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
|
|
20
|
+
IN1000000000000000000014 /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Platforms/MacOSX.platform/Developer/Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; };
|
|
21
|
+
IN1000000000000000000021 /* RNFBInstallationsHelper.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = RNFBInstallationsHelper.m; path = ../RNFBInstallations/RNFBInstallationsHelper.m; sourceTree = SOURCE_ROOT; };
|
|
22
|
+
IN1000000000000000000023 /* RNFBInstallationsHelperHostStubTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNFBInstallationsHelperHostStubTests.m; sourceTree = "<group>"; };
|
|
23
|
+
IN1000000000000000000025 /* FIRInstallationsHostStub.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = FIRInstallationsHostStub.m; path = HostStubs/Firebase/FIRInstallationsHostStub.m; sourceTree = "<group>"; };
|
|
24
|
+
IN1000000000000000000027 /* RNFBSharedUtilsHostStub.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = RNFBSharedUtilsHostStub.m; path = HostStubs/RNFBApp/RNFBSharedUtilsHostStub.m; sourceTree = "<group>"; };
|
|
25
|
+
IN1000000000000000000029 /* RCTConvert+FIRAppHostStub.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = "RCTConvert+FIRAppHostStub.m"; path = "HostStubs/RNFBApp/RCTConvert+FIRAppHostStub.m"; sourceTree = "<group>"; };
|
|
26
|
+
IN100000000000000000002A /* RNFBInstallationsHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = RNFBInstallationsHelper.h; path = ../RNFBInstallations/RNFBInstallationsHelper.h; sourceTree = SOURCE_ROOT; };
|
|
27
|
+
/* End PBXFileReference section */
|
|
28
|
+
|
|
29
|
+
/* Begin PBXFrameworksBuildPhase section */
|
|
30
|
+
IN1000000000000000000012 /* Frameworks */ = {
|
|
31
|
+
isa = PBXFrameworksBuildPhase;
|
|
32
|
+
buildActionMask = 2147483647;
|
|
33
|
+
files = (
|
|
34
|
+
IN1000000000000000000015 /* XCTest.framework in Frameworks */,
|
|
35
|
+
);
|
|
36
|
+
runOnlyForDeploymentPostprocessing = 0;
|
|
37
|
+
};
|
|
38
|
+
/* End PBXFrameworksBuildPhase section */
|
|
39
|
+
|
|
40
|
+
/* Begin PBXGroup section */
|
|
41
|
+
IN1000000000000000000004 = {
|
|
42
|
+
isa = PBXGroup;
|
|
43
|
+
children = (
|
|
44
|
+
IN1000000000000000000006 /* Sources */,
|
|
45
|
+
IN1000000000000000000005 /* Products */,
|
|
46
|
+
);
|
|
47
|
+
sourceTree = "<group>";
|
|
48
|
+
};
|
|
49
|
+
IN1000000000000000000005 /* Products */ = {
|
|
50
|
+
isa = PBXGroup;
|
|
51
|
+
children = (
|
|
52
|
+
IN1000000000000000000003 /* RNFBInstallationsUnitTests.xctest */,
|
|
53
|
+
);
|
|
54
|
+
name = Products;
|
|
55
|
+
sourceTree = "<group>";
|
|
56
|
+
};
|
|
57
|
+
IN1000000000000000000006 /* Sources */ = {
|
|
58
|
+
isa = PBXGroup;
|
|
59
|
+
children = (
|
|
60
|
+
IN100000000000000000002A /* RNFBInstallationsHelper.h */,
|
|
61
|
+
IN1000000000000000000021 /* RNFBInstallationsHelper.m */,
|
|
62
|
+
IN1000000000000000000023 /* RNFBInstallationsHelperHostStubTests.m */,
|
|
63
|
+
IN1000000000000000000025 /* FIRInstallationsHostStub.m */,
|
|
64
|
+
IN1000000000000000000027 /* RNFBSharedUtilsHostStub.m */,
|
|
65
|
+
IN1000000000000000000029 /* RCTConvert+FIRAppHostStub.m */,
|
|
66
|
+
);
|
|
67
|
+
name = Sources;
|
|
68
|
+
sourceTree = "<group>";
|
|
69
|
+
};
|
|
70
|
+
/* End PBXGroup section */
|
|
71
|
+
|
|
72
|
+
/* Begin PBXNativeTarget section */
|
|
73
|
+
IN1000000000000000000002 /* RNFBInstallationsUnitTests */ = {
|
|
74
|
+
isa = PBXNativeTarget;
|
|
75
|
+
buildConfigurationList = IN1000000000000000000013 /* Build configuration list for PBXNativeTarget "RNFBInstallationsUnitTests" */;
|
|
76
|
+
buildPhases = (
|
|
77
|
+
IN1000000000000000000016 /* Sources */,
|
|
78
|
+
IN1000000000000000000012 /* Frameworks */,
|
|
79
|
+
);
|
|
80
|
+
buildRules = (
|
|
81
|
+
);
|
|
82
|
+
dependencies = (
|
|
83
|
+
);
|
|
84
|
+
name = RNFBInstallationsUnitTests;
|
|
85
|
+
productName = RNFBInstallationsUnitTests;
|
|
86
|
+
productReference = IN1000000000000000000003 /* RNFBInstallationsUnitTests.xctest */;
|
|
87
|
+
productType = "com.apple.product-type.bundle.unit-test";
|
|
88
|
+
};
|
|
89
|
+
/* End PBXNativeTarget section */
|
|
90
|
+
|
|
91
|
+
/* Begin PBXProject section */
|
|
92
|
+
IN1000000000000000000001 /* Project object */ = {
|
|
93
|
+
isa = PBXProject;
|
|
94
|
+
attributes = {
|
|
95
|
+
BuildIndependentTargetsInParallel = 1;
|
|
96
|
+
LastUpgradeCheck = 2600;
|
|
97
|
+
ORGANIZATIONNAME = Invertase;
|
|
98
|
+
TargetAttributes = {
|
|
99
|
+
IN1000000000000000000002 = {
|
|
100
|
+
CreatedOnToolsVersion = 26.0;
|
|
101
|
+
};
|
|
102
|
+
};
|
|
103
|
+
};
|
|
104
|
+
buildConfigurationList = IN1000000000000000000017 /* Build configuration list for PBXProject "RNFBInstallationsUnitTests" */;
|
|
105
|
+
compatibilityVersion = "Xcode 14.0";
|
|
106
|
+
developmentRegion = en;
|
|
107
|
+
hasScannedForEncodings = 0;
|
|
108
|
+
knownRegions = (
|
|
109
|
+
en,
|
|
110
|
+
Base,
|
|
111
|
+
);
|
|
112
|
+
mainGroup = IN1000000000000000000004;
|
|
113
|
+
productRefGroup = IN1000000000000000000005 /* Products */;
|
|
114
|
+
projectDirPath = "";
|
|
115
|
+
projectRoot = "";
|
|
116
|
+
targets = (
|
|
117
|
+
IN1000000000000000000002 /* RNFBInstallationsUnitTests */,
|
|
118
|
+
);
|
|
119
|
+
};
|
|
120
|
+
/* End PBXProject section */
|
|
121
|
+
|
|
122
|
+
/* Begin PBXSourcesBuildPhase section */
|
|
123
|
+
IN1000000000000000000016 /* Sources */ = {
|
|
124
|
+
isa = PBXSourcesBuildPhase;
|
|
125
|
+
buildActionMask = 2147483647;
|
|
126
|
+
files = (
|
|
127
|
+
IN1000000000000000000020 /* RNFBInstallationsHelper.m in Sources */,
|
|
128
|
+
IN1000000000000000000024 /* FIRInstallationsHostStub.m in Sources */,
|
|
129
|
+
IN1000000000000000000026 /* RNFBSharedUtilsHostStub.m in Sources */,
|
|
130
|
+
IN1000000000000000000028 /* RCTConvert+FIRAppHostStub.m in Sources */,
|
|
131
|
+
IN1000000000000000000022 /* RNFBInstallationsHelperHostStubTests.m in Sources */,
|
|
132
|
+
);
|
|
133
|
+
runOnlyForDeploymentPostprocessing = 0;
|
|
134
|
+
};
|
|
135
|
+
/* End PBXSourcesBuildPhase section */
|
|
136
|
+
|
|
137
|
+
/* Begin XCBuildConfiguration section */
|
|
138
|
+
IN1000000000000000000018 /* Debug */ = {
|
|
139
|
+
isa = XCBuildConfiguration;
|
|
140
|
+
buildSettings = {
|
|
141
|
+
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
142
|
+
CLANG_ENABLE_MODULES = YES;
|
|
143
|
+
CLANG_ENABLE_OBJC_ARC = YES;
|
|
144
|
+
COPY_PHASE_STRIP = NO;
|
|
145
|
+
DEBUG_INFORMATION_FORMAT = dwarf;
|
|
146
|
+
ENABLE_TESTABILITY = YES;
|
|
147
|
+
GCC_C_LANGUAGE_STANDARD = gnu17;
|
|
148
|
+
GCC_DYNAMIC_NO_PIC = NO;
|
|
149
|
+
GCC_OPTIMIZATION_LEVEL = 0;
|
|
150
|
+
MACOSX_DEPLOYMENT_TARGET = 14.0;
|
|
151
|
+
ONLY_ACTIVE_ARCH = YES;
|
|
152
|
+
SDKROOT = macosx;
|
|
153
|
+
SUPPORTED_PLATFORMS = macosx;
|
|
154
|
+
};
|
|
155
|
+
name = Debug;
|
|
156
|
+
};
|
|
157
|
+
IN1000000000000000000019 /* Release */ = {
|
|
158
|
+
isa = XCBuildConfiguration;
|
|
159
|
+
buildSettings = {
|
|
160
|
+
ALWAYS_SEARCH_USER_PATHS = NO;
|
|
161
|
+
CLANG_ENABLE_MODULES = YES;
|
|
162
|
+
CLANG_ENABLE_OBJC_ARC = YES;
|
|
163
|
+
COPY_PHASE_STRIP = YES;
|
|
164
|
+
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
|
165
|
+
GCC_C_LANGUAGE_STANDARD = gnu17;
|
|
166
|
+
MACOSX_DEPLOYMENT_TARGET = 14.0;
|
|
167
|
+
SDKROOT = macosx;
|
|
168
|
+
SUPPORTED_PLATFORMS = macosx;
|
|
169
|
+
};
|
|
170
|
+
name = Release;
|
|
171
|
+
};
|
|
172
|
+
IN100000000000000000001A /* Debug */ = {
|
|
173
|
+
isa = XCBuildConfiguration;
|
|
174
|
+
buildSettings = {
|
|
175
|
+
CLANG_ENABLE_CODE_COVERAGE = YES;
|
|
176
|
+
CODE_SIGNING_ALLOWED = NO;
|
|
177
|
+
CODE_SIGNING_REQUIRED = NO;
|
|
178
|
+
CODE_SIGN_IDENTITY = "-";
|
|
179
|
+
COMBINE_HIDPI_IMAGES = YES;
|
|
180
|
+
GENERATE_INFOPLIST_FILE = YES;
|
|
181
|
+
HEADER_SEARCH_PATHS = (
|
|
182
|
+
"$(SRCROOT)/HostStubs",
|
|
183
|
+
"$(SRCROOT)/../RNFBInstallations",
|
|
184
|
+
);
|
|
185
|
+
LD_RUNPATH_SEARCH_PATHS = (
|
|
186
|
+
"$(inherited)",
|
|
187
|
+
"@executable_path/../Frameworks",
|
|
188
|
+
"@loader_path/../Frameworks",
|
|
189
|
+
);
|
|
190
|
+
MACOSX_DEPLOYMENT_TARGET = 14.0;
|
|
191
|
+
OTHER_CFLAGS = (
|
|
192
|
+
"-fprofile-instr-generate",
|
|
193
|
+
"-fcoverage-mapping",
|
|
194
|
+
);
|
|
195
|
+
OTHER_LDFLAGS = (
|
|
196
|
+
"-fprofile-instr-generate",
|
|
197
|
+
);
|
|
198
|
+
PRODUCT_BUNDLE_IDENTIFIER = io.invertase.firebase.RNFBInstallationsUnitTests;
|
|
199
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
|
200
|
+
SDKROOT = macosx;
|
|
201
|
+
SUPPORTED_PLATFORMS = macosx;
|
|
202
|
+
};
|
|
203
|
+
name = Debug;
|
|
204
|
+
};
|
|
205
|
+
IN100000000000000000001B /* Release */ = {
|
|
206
|
+
isa = XCBuildConfiguration;
|
|
207
|
+
buildSettings = {
|
|
208
|
+
CLANG_ENABLE_CODE_COVERAGE = YES;
|
|
209
|
+
CODE_SIGNING_ALLOWED = NO;
|
|
210
|
+
CODE_SIGNING_REQUIRED = NO;
|
|
211
|
+
CODE_SIGN_IDENTITY = "-";
|
|
212
|
+
COMBINE_HIDPI_IMAGES = YES;
|
|
213
|
+
GENERATE_INFOPLIST_FILE = YES;
|
|
214
|
+
HEADER_SEARCH_PATHS = (
|
|
215
|
+
"$(SRCROOT)/HostStubs",
|
|
216
|
+
"$(SRCROOT)/../RNFBInstallations",
|
|
217
|
+
);
|
|
218
|
+
LD_RUNPATH_SEARCH_PATHS = (
|
|
219
|
+
"$(inherited)",
|
|
220
|
+
"@executable_path/../Frameworks",
|
|
221
|
+
"@loader_path/../Frameworks",
|
|
222
|
+
);
|
|
223
|
+
MACOSX_DEPLOYMENT_TARGET = 14.0;
|
|
224
|
+
PRODUCT_BUNDLE_IDENTIFIER = io.invertase.firebase.RNFBInstallationsUnitTests;
|
|
225
|
+
PRODUCT_NAME = "$(TARGET_NAME)";
|
|
226
|
+
SDKROOT = macosx;
|
|
227
|
+
SUPPORTED_PLATFORMS = macosx;
|
|
228
|
+
};
|
|
229
|
+
name = Release;
|
|
230
|
+
};
|
|
231
|
+
/* End XCBuildConfiguration section */
|
|
232
|
+
|
|
233
|
+
/* Begin XCConfigurationList section */
|
|
234
|
+
IN1000000000000000000017 /* Build configuration list for PBXProject "RNFBInstallationsUnitTests" */ = {
|
|
235
|
+
isa = XCConfigurationList;
|
|
236
|
+
buildConfigurations = (
|
|
237
|
+
IN1000000000000000000018 /* Debug */,
|
|
238
|
+
IN1000000000000000000019 /* Release */,
|
|
239
|
+
);
|
|
240
|
+
defaultConfigurationIsVisible = 0;
|
|
241
|
+
defaultConfigurationName = Debug;
|
|
242
|
+
};
|
|
243
|
+
IN1000000000000000000013 /* Build configuration list for PBXNativeTarget "RNFBInstallationsUnitTests" */ = {
|
|
244
|
+
isa = XCConfigurationList;
|
|
245
|
+
buildConfigurations = (
|
|
246
|
+
IN100000000000000000001A /* Debug */,
|
|
247
|
+
IN100000000000000000001B /* Release */,
|
|
248
|
+
);
|
|
249
|
+
defaultConfigurationIsVisible = 0;
|
|
250
|
+
defaultConfigurationName = Debug;
|
|
251
|
+
};
|
|
252
|
+
/* End XCConfigurationList section */
|
|
253
|
+
};
|
|
254
|
+
rootObject = IN1000000000000000000001 /* Project object */;
|
|
255
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<Scheme
|
|
3
|
+
LastUpgradeVersion = "2600"
|
|
4
|
+
version = "1.7">
|
|
5
|
+
<BuildAction
|
|
6
|
+
parallelizeBuildables = "YES"
|
|
7
|
+
buildImplicitDependencies = "YES">
|
|
8
|
+
<BuildActionEntries>
|
|
9
|
+
<BuildActionEntry
|
|
10
|
+
buildForTesting = "YES"
|
|
11
|
+
buildForRunning = "YES"
|
|
12
|
+
buildForProfiling = "NO"
|
|
13
|
+
buildForArchiving = "NO"
|
|
14
|
+
buildForAnalyzing = "YES">
|
|
15
|
+
<BuildableReference
|
|
16
|
+
BuildableIdentifier = "primary"
|
|
17
|
+
BlueprintIdentifier = "IN1000000000000000000002"
|
|
18
|
+
BuildableName = "RNFBInstallationsUnitTests.xctest"
|
|
19
|
+
BlueprintName = "RNFBInstallationsUnitTests"
|
|
20
|
+
ReferencedContainer = "container:RNFBInstallationsUnitTests.xcodeproj">
|
|
21
|
+
</BuildableReference>
|
|
22
|
+
</BuildActionEntry>
|
|
23
|
+
</BuildActionEntries>
|
|
24
|
+
</BuildAction>
|
|
25
|
+
<TestAction
|
|
26
|
+
buildConfiguration = "Debug"
|
|
27
|
+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
|
28
|
+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
|
29
|
+
shouldUseLaunchSchemeArgsEnv = "YES"
|
|
30
|
+
codeCoverageEnabled = "YES">
|
|
31
|
+
<Testables>
|
|
32
|
+
<TestableReference
|
|
33
|
+
skipped = "NO">
|
|
34
|
+
<BuildableReference
|
|
35
|
+
BuildableIdentifier = "primary"
|
|
36
|
+
BlueprintIdentifier = "IN1000000000000000000002"
|
|
37
|
+
BuildableName = "RNFBInstallationsUnitTests.xctest"
|
|
38
|
+
BlueprintName = "RNFBInstallationsUnitTests"
|
|
39
|
+
ReferencedContainer = "container:RNFBInstallationsUnitTests.xcodeproj">
|
|
40
|
+
</BuildableReference>
|
|
41
|
+
</TestableReference>
|
|
42
|
+
</Testables>
|
|
43
|
+
</TestAction>
|
|
44
|
+
<LaunchAction
|
|
45
|
+
buildConfiguration = "Debug"
|
|
46
|
+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
|
47
|
+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
|
48
|
+
launchStyle = "0"
|
|
49
|
+
useCustomWorkingDirectory = "NO"
|
|
50
|
+
ignoresPersistentStateOnLaunch = "NO"
|
|
51
|
+
debugDocumentVersioning = "YES"
|
|
52
|
+
debugServiceExtension = "internal"
|
|
53
|
+
allowLocationSimulation = "YES">
|
|
54
|
+
</LaunchAction>
|
|
55
|
+
<ProfileAction
|
|
56
|
+
buildConfiguration = "Release"
|
|
57
|
+
shouldUseLaunchSchemeArgsEnv = "YES"
|
|
58
|
+
savedToolIdentifier = ""
|
|
59
|
+
useCustomWorkingDirectory = "NO"
|
|
60
|
+
debugDocumentVersioning = "YES">
|
|
61
|
+
</ProfileAction>
|
|
62
|
+
<AnalyzeAction
|
|
63
|
+
buildConfiguration = "Debug">
|
|
64
|
+
</AnalyzeAction>
|
|
65
|
+
<ArchiveAction
|
|
66
|
+
buildConfiguration = "Release"
|
|
67
|
+
revealArchiveInOrganizer = "YES">
|
|
68
|
+
</ArchiveAction>
|
|
69
|
+
</Scheme>
|
package/lib/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Generated by genversion.
|
|
2
|
-
export const version = '
|
|
2
|
+
export const version = '27.0.0';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@react-native-firebase/installations",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "27.0.0",
|
|
4
4
|
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
|
|
5
5
|
"description": "React Native Firebase - Installations",
|
|
6
6
|
"main": "./dist/module/index.js",
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
"android:codegen": "node ../../scripts/codegen-package.mjs installations android",
|
|
29
29
|
"ios:codegen": "node ../../scripts/codegen-package.mjs installations ios"
|
|
30
30
|
},
|
|
31
|
+
"homepage": "https://rnfirebase.io",
|
|
31
32
|
"repository": {
|
|
32
33
|
"type": "git",
|
|
33
34
|
"url": "https://github.com/invertase/react-native-firebase",
|
|
@@ -41,14 +42,14 @@
|
|
|
41
42
|
"installations"
|
|
42
43
|
],
|
|
43
44
|
"peerDependencies": {
|
|
44
|
-
"@react-native-firebase/app": "
|
|
45
|
+
"@react-native-firebase/app": "27.0.0"
|
|
45
46
|
},
|
|
46
47
|
"publishConfig": {
|
|
47
48
|
"access": "public",
|
|
48
49
|
"provenance": true
|
|
49
50
|
},
|
|
50
51
|
"devDependencies": {
|
|
51
|
-
"@react-native-firebase/app": "
|
|
52
|
+
"@react-native-firebase/app": "27.0.0",
|
|
52
53
|
"react-native-builder-bob": "^0.40.13"
|
|
53
54
|
},
|
|
54
55
|
"exports": {
|
|
@@ -77,5 +78,5 @@
|
|
|
77
78
|
]
|
|
78
79
|
]
|
|
79
80
|
},
|
|
80
|
-
"gitHead": "
|
|
81
|
+
"gitHead": "0c7e942bca361f1765abaf233bf447d795718eff"
|
|
81
82
|
}
|