File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
example/ios/InstabugSampleTests Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -72,13 +72,17 @@ - (void) testgivenHandler$setOnInvokeHandler_whenQuery_thenShouldCallNativeApi {
7272
7373- (void ) testgivenHandlerCANCEL $setOnDismissHandler_whenQuery_thenShouldCallNativeApi {
7474 id partialMock = OCMPartialMock (self.instabugBridge );
75+ IBGDismissType dismissType = IBGDismissTypeCancel;
76+ IBGReportType reportType = IBGReportTypeBug;
77+
7578 RCTResponseSenderBlock callback = ^(NSArray *response) {};
7679 [partialMock setOnDismissHandler: callback];
7780 XCTAssertNotNil (IBGBugReporting.didDismissHandler );
78- NSDictionary *result = @{ @" dismissType" : @" CANCEL" ,
79- @" reportType" : @" bug" };
81+ NSDictionary *result = @{ @" dismissType" : @(dismissType),
82+ @" reportType" : @(reportType)};
83+
8084 OCMStub ([partialMock sendEventWithName: @" IBGpostInvocationHandler" body: result]);
81- IBGBugReporting.didDismissHandler (IBGDismissTypeCancel,IBGReportTypeBug );
85+ IBGBugReporting.didDismissHandler (dismissType, reportType );
8286 OCMVerify ([partialMock sendEventWithName: @" IBGpostInvocationHandler" body: result]);
8387}
8488
You can’t perform that action at this time.
0 commit comments