forked from facebook/facebook-ios-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Summary: As title Reviewed By: dreamolight Differential Revision: D23956881 fbshipit-source-id: f2150cb5bb15ed96f07324f4a83f548369365081
- Loading branch information
1 parent
c8c628b
commit 3d02460
Showing
2 changed files
with
26 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -291,6 +291,30 @@ - (void)testAdvertiserTrackingEnabledInAppEventPayload | |
} | ||
} | ||
|
||
- (void)testDropAppEvent | ||
{ | ||
id mockAppEventsState = OCMClassMock([FBSDKAppEventsState class]); | ||
OCMStub([mockAppEventsState alloc]).andReturn(mockAppEventsState); | ||
OCMStub([mockAppEventsState initWithToken:OCMArg.any appID:OCMArg.any]).andReturn(mockAppEventsState); | ||
[FBSDKSettings setAppID:@"123"]; | ||
|
||
OCMStub([_mockAppEventsUtility shouldDropAppEvent]).andReturn(YES); | ||
[FBSDKAppEvents logEvent:@"event"]; | ||
OCMReject([mockAppEventsState addEvent:OCMArg.any isImplicit:NO]); | ||
} | ||
|
||
- (void)testSendAppEvent | ||
{ | ||
id mockAppEventsState = OCMClassMock([FBSDKAppEventsState class]); | ||
OCMStub([mockAppEventsState alloc]).andReturn(mockAppEventsState); | ||
OCMStub([mockAppEventsState initWithToken:OCMArg.any appID:OCMArg.any]).andReturn(mockAppEventsState); | ||
[FBSDKSettings setAppID:@"123"]; | ||
|
||
OCMStub([_mockAppEventsUtility shouldDropAppEvent]).andReturn(NO); | ||
[FBSDKAppEvents logEvent:@"event"]; | ||
OCMVerify([mockAppEventsState addEvent:OCMArg.any isImplicit:NO]); | ||
} | ||
|
||
- (void)testIsSensitiveUserData | ||
{ | ||
NSString *text = @"[email protected]"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters