Skip to content

Commit c34ed56

Browse files
committed
fix(android): fix test case
1 parent 09c1e9d commit c34ed56

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

android/src/test/java/com/instabug/flutter/util/GlobalMocks.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,13 @@ public static void setUp() throws NoSuchMethodException {
5757
Bitmap.class, String.class))
5858
.thenReturn(mReportScreenChange);
5959

60+
Method mReportCurrentViewChange= MockReflected.class.getDeclaredMethod("reportCurrentViewChange", String.class);
61+
mReportCurrentViewChange.setAccessible(true);
62+
reflection
63+
.when(() -> Reflection.getMethod(Class.forName("com.instabug.library.Instabug"), "reportCurrentViewChange",
64+
String.class))
65+
.thenReturn(mReportCurrentViewChange);
66+
6067
Method mSetCustomBrandingImage = MockReflected.class.getDeclaredMethod("setCustomBrandingImage", Bitmap.class, Bitmap.class);
6168
mSetCustomBrandingImage.setAccessible(true);
6269
reflection

0 commit comments

Comments
 (0)