@@ -157,8 +157,8 @@ class IdentityToolkitRequestTests: XCTestCase {
157
157
auth: auth, tenantConfig: tenantConfig)
158
158
let request = IdentityToolkitRequest ( endpoint: kEndpoint,
159
159
requestConfiguration: requestConfiguration)
160
- let expectedURL = " https://identityplatform.googleapis.com/v2 /projects/ \( kProjectID) " +
161
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
160
+ let expectedURL = " https://identityplatform.googleapis.com/v2alpha /projects/ \( kProjectID) " +
161
+ " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs: \( kEndpoint) ?key= \( kAPIKey) "
162
162
XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
163
163
}
164
164
@@ -182,33 +182,8 @@ class IdentityToolkitRequestTests: XCTestCase {
182
182
requestConfiguration: requestConfiguration,
183
183
useStaging: true )
184
184
let expectedURL =
185
- " https://staging-identityplatform.sandbox.googleapis.com/v2/projects/ \( kProjectID) " +
186
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
187
- XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
188
- }
189
-
190
- /** @fn testInitWithRGCIPIUseEmulatorExpectedRequestURL
191
- @brief Tests the @c requestURL method for R-GCIP with location, tenant ID, and emulator.
192
- */
193
- func testInitWithRGCIPIUseEmulatorExpectedRequestURL( ) {
194
- let options = FirebaseOptions ( googleAppID: " 0:0000000000000:ios:0000000000000000 " ,
195
- gcmSenderID: " 00000000000000000-00000000000-000000000 " )
196
- options. apiKey = kAPIKey
197
- options. projectID = kProjectID
198
- let app = FirebaseApp ( instanceWithName: " rGCIPAppEmulator " , options: options)
199
- // Force initialize Auth for the app to set the weak reference in AuthRequestConfiguration
200
- let auth = Auth ( app: app)
201
- auth. tenantID = kTenantID
202
-
203
- let tenantConfig = TenantConfig ( tenantId: kTenantID, location: kLocation)
204
- let requestConfiguration = AuthRequestConfiguration ( apiKey: kAPIKey, appID: " appID " ,
205
- auth: auth, tenantConfig: tenantConfig)
206
- requestConfiguration. emulatorHostAndPort = kEmulatorHostAndPort
207
- let request = IdentityToolkitRequest ( endpoint: kEndpoint,
208
- requestConfiguration: requestConfiguration)
209
- let expectedURL =
210
- " http:// \( kEmulatorHostAndPort) /identityplatform.googleapis.com/v2/projects/ \( kProjectID) " +
211
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
185
+ " https://staging-identityplatform.sandbox.googleapis.com/v2alpha/projects/ \( kProjectID) " +
186
+ " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs: \( kEndpoint) ?key= \( kAPIKey) "
212
187
XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
213
188
}
214
189
@@ -232,8 +207,8 @@ class IdentityToolkitRequestTests: XCTestCase {
232
207
let request = IdentityToolkitRequest ( endpoint: kEndpoint,
233
208
requestConfiguration: requestConfiguration)
234
209
// The expected URL should use "projectID" as a placeholder
235
- let expectedURL = " https://identityplatform.googleapis.com/v2 /projects/projectID " +
236
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
210
+ let expectedURL = " https://identityplatform.googleapis.com/v2alpha /projects/projectID " +
211
+ " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs: \( kEndpoint) ?key= \( kAPIKey) "
237
212
XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
238
213
}
239
214
@@ -359,8 +334,8 @@ class IdentityToolkitRequestTests: XCTestCase {
359
334
requestConfiguration: requestConfiguration,
360
335
useIdentityPlatform: true ) // useIdentityPlatform is true
361
336
362
- let expectedURL = " https://identityplatform.googleapis.com/v2 /projects/ \( kProjectID) " +
363
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
337
+ let expectedURL = " https://identityplatform.googleapis.com/v2alpha /projects/ \( kProjectID) " +
338
+ " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs: \( kEndpoint) ?key= \( kAPIKey) "
364
339
XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
365
340
}
366
341
@@ -384,8 +359,8 @@ class IdentityToolkitRequestTests: XCTestCase {
384
359
let request = IdentityToolkitRequest ( endpoint: kEndpoint,
385
360
requestConfiguration: requestConfiguration)
386
361
387
- let expectedURL = " https://identityplatform.googleapis.com/v2 /projects/ \( kProjectID) " +
388
- " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs/ \( kEndpoint) ?key= \( kAPIKey) "
362
+ let expectedURL = " https://identityplatform.googleapis.com/v2alpha /projects/ \( kProjectID) " +
363
+ " /locations/ \( kLocation) /tenants/ \( kTenantID) /idpConfigs: \( kEndpoint) ?key= \( kAPIKey) "
389
364
XCTAssertEqual ( expectedURL, request. requestURL ( ) . absoluteString)
390
365
}
391
366
0 commit comments