From f08edbb85c5cbde74c354c478ac9433d2417d748 Mon Sep 17 00:00:00 2001 From: Bryan Klimt Date: Thu, 21 Jun 2018 15:25:13 -0400 Subject: Add a couple of new small Functions APIs. (#1434) * Add a Functions constructor that allows setting a region. * Add a method to set an emulator origin to use. * Update the changelog --- Functions/Example/Tests/FIRFunctionsTests.m | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'Functions/Example/Tests/FIRFunctionsTests.m') diff --git a/Functions/Example/Tests/FIRFunctionsTests.m b/Functions/Example/Tests/FIRFunctionsTests.m index 5d11601..fdce514 100644 --- a/Functions/Example/Tests/FIRFunctionsTests.m +++ b/Functions/Example/Tests/FIRFunctionsTests.m @@ -33,17 +33,13 @@ } - (void)testURLWithName { - // TODO(klimt): Add this test back when we add the constructor back. - /* id app = [[FUNFakeApp alloc] initWithProjectID:@"my-project"]; FIRFunctions *functions = [FIRFunctions functionsForApp:app region:@"my-region"]; NSString *url = [functions URLWithName:@"my-endpoint"]; XCTAssertEqualObjects(@"https://my-region-my-project.cloudfunctions.net/my-endpoint", url); - */ - id app = [[FUNFakeApp alloc] initWithProjectID:@"my-project"]; - FIRFunctions *functions = [FIRFunctions functionsForApp:app]; - NSString *url = [functions URLWithName:@"my-endpoint"]; + functions = [FIRFunctions functionsForApp:app]; + url = [functions URLWithName:@"my-endpoint"]; XCTAssertEqualObjects(@"https://us-central1-my-project.cloudfunctions.net/my-endpoint", url); } -- cgit v1.2.3