Skip to content

Commit 41d4fe3

Browse files
committed
adding attachment assert to the nse unit test
1 parent 6909cea commit 41d4fe3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

iOS_SDK/OneSignalSDK/UnitTests/UnitTests.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1839,7 +1839,7 @@ - (void)testAddingSharedKeysIfMissing {
18391839
}
18401840

18411841
// iOS 10 - Notification Service Extension test - local file
1842-
- (void) testDidReceiveNotificationExtensionRequestLocalFile {
1842+
- (void)testDidReceiveNotificationExtensionRequestLocalFile {
18431843
id userInfo = @{@"aps": @{
18441844
@"mutable-content": @1,
18451845
@"alert": @"Message Body"
@@ -1910,6 +1910,9 @@ - (void) testServiceExtensionContentHandlerFired {
19101910
[contentExpectation fulfill];
19111911
// Make sure butons were added.
19121912
XCTAssertEqualObjects(content.categoryIdentifier, @"__onesignal__dynamic__b2f7f966-d8cc-11e4-bed1-df8f05be55ba");
1913+
// Make sure attachments were added.
1914+
XCTAssertEqualObjects(content.attachments[0].identifier, @"id");
1915+
XCTAssertEqualObjects(content.attachments[0].URL.scheme, @"file");
19131916
});
19141917
[self waitForExpectations:@[contentExpectation] timeout:1];
19151918
}

0 commit comments

Comments
 (0)