Skip to content

Commit 959f555

Browse files
committed
Fixing API test to use different public API due github issue with 403 on git api calls
1 parent d78a027 commit 959f555

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

libs/SalesforceSDKCore/SalesforceSDKCoreTests/SalesforceRestAPITests.m

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2898,8 +2898,14 @@ - (void)testPublicApiCalls {
28982898
XCTestExpectation *getExpectation = [self expectationWithDescription:@"Get"];
28992899
__block NSError *error = nil;
29002900
__block NSDictionary *response = nil;
2901-
SFRestRequest *request = [SFRestRequest customUrlRequestWithMethod:SFRestMethodGET baseURL:@"https://api.github.com" path:@"/orgs/forcedotcom/repos" queryParams:nil];
2902-
XCTAssertEqual(request.baseURL, @"https://api.github.com", @"Base URL should match");
2901+
NSString *testBaseURL = @"https://mobilesdk.my.salesforce.com";
2902+
NSString *testPathURL = @"/.well-known/auth-configuration";
2903+
SFRestRequest *request = [SFRestRequest customUrlRequestWithMethod:SFRestMethodGET
2904+
baseURL:testBaseURL
2905+
path:testPathURL
2906+
queryParams:nil];
2907+
XCTAssertEqual(request.baseURL, testBaseURL, @"Base URL should match");
2908+
XCTAssertEqual(request.path, testPathURL, @"Path URL should match");
29032909
[[SFRestAPI sharedGlobalInstance] sendRequest:request failureBlock:^(id resp, NSError *e, NSURLResponse *rawResponse) {
29042910
error = e;
29052911
[getExpectation fulfill];

0 commit comments

Comments
 (0)