Skip to content

Commit 15d39b2

Browse files
authored
[Mob 3196] - [MOB-3201]: Flutter API [BugReporting] (#58)
* Android API Mappings & Enums * IOS API Mapping & Enums * Flutter API Mapping * Adds tests for new API * updates Readme * updated Changelog ## Mapped APIs: * setInvocationEvents * setEnabledAttachmentTypes * setReportTypes * setExtendedBugReportMode * setInvocationOptions * showWithOptions
1 parent 4cc25f0 commit 15d39b2

File tree

9 files changed

+585
-216
lines changed

9 files changed

+585
-216
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
## Master
22

3+
* Adds showWithOptions API mapping.
4+
* Adds setInvocationOptions API mapping.
5+
* Adds setExtendedBugReportMode API mapping.
6+
* Adds setReportTypes API mapping.
7+
* Adds setEnabledAttachmentTypes API mapping.
8+
* Adds setInvocationEvents API mapping.
39
* Adds setOnDismissCallback API mapping.
410
* Adds setOnInvokeCallback API mapping.
511
* Adds BugReporting.setEnabled API mapping.

README.md

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,12 @@ The section below contains the APIs we're planning to implement for our 1.0 rele
5959
| `setEnabled(bool isEnabled)` | `setState(Feature.State state)`<br>`enabled` |
6060
| `setOnInvokeCallback(Function function)` | `setOnInvokeCallback(OnInvokeCallback onInvokeCallback)`<br>`willInvokeHandler` |
6161
| `setOnDismissCallback(Function function)` | `setOnDismissCallback(OnSdkDismissCallback onSdkDismissedCallback)`<br>`didDismissHandler` |
62-
| | `setInvocationEvents(InstabugInvocationEvent... invocationEvents)`<br>`invocationEvents` |
63-
| | `setAttachmentTypesEnabled(boolean initial, boolean extra, boolean gallery, boolean recording`<br>`enabledAttachmentTypes` |
64-
| | `setReportTypes(@BugReporting.ReportType int... types)`<br>`promptOptionsEnabledReportTypes` |
65-
| | `setExtendedBugReportState(ExtendedBugReport.State state)`<br>`extendedBugReportMode` |
66-
| | `setOptions(@Option int... options)`<br>`bugReportingOptions`
67-
| | `show(@BugReporting.ReportType int type)`<br>`+ showWithReportType:options:`
62+
| `setInvocationEvents(List<InvocationEvent> invocationEvents)` | `setInvocationEvents(InstabugInvocationEvent... invocationEvents)`<br>`invocationEvents` |
63+
| `setEnabledAttachmentTypes(bool screenshot, bool extraScreenshot, bool galleryImage, bool screenRecording)` | `setAttachmentTypesEnabled(boolean initial, boolean extra, boolean gallery, boolean recording`<br>`enabledAttachmentTypes` |
64+
| `setReportTypes(List<ReportType> reportTypes)` | `setReportTypes(@BugReporting.ReportType int... types)`<br>`promptOptionsEnabledReportTypes` |
65+
| `setExtendedBugReportMode(ExtendedBugReportMode extendedBugReportMode)` | `setExtendedBugReportState(ExtendedBugReport.State state)`<br>`extendedBugReportMode` |
66+
| `setInvocationOptions(List<InvocationOption> invocationOptions)` | `setOptions(@Option int... options)`<br>`bugReportingOptions`
67+
| `showWithOptions(ReportType reportType, List<InvocationOption> invocationOptions)` | `show(@BugReporting.ReportType int type)`<br>`+ showWithReportType:options:`
6868

6969
#### `InstabugLog`
7070

@@ -146,7 +146,11 @@ invocationEvents.add(InstabugFlutterPlugin.INVOCATION_EVENT_SHAKE);
146146
new InstabugFlutterPlugin().start(CustomFlutterApplication.this, "APP_TOKEN", invocationEvents);
147147
```
148148

149-
5. For iOS apps, Instabug needs access to the microphone and photo library to be able to let users add audio and video attachments. Add the following 2 keys to your app’s `Info.plist` file with text explaining to the user why those permissions are needed:
149+
## Microphone and Photo Library Usage Description (iOS Only)
150+
151+
Instabug needs access to the microphone and photo library to be able to let users add audio and video attachments. Starting from iOS 10, apps that don’t provide a usage description for those 2 permissions would be rejected when submitted to the App Store.
152+
153+
For your app not to be rejected, you’ll need to add the following 2 keys to your app’s info.plist file with text explaining to the user why those permissions are needed:
150154

151155
* `NSMicrophoneUsageDescription`
152156
* `NSPhotoLibraryUsageDescription`

android/src/main/java/com/instabug/instabugflutter/ArgsRegistry.java

Lines changed: 76 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import com.instabug.bug.invocation.Option;
88
import com.instabug.library.InstabugColorTheme;
99
import com.instabug.library.InstabugCustomTextPlaceHolder;
10+
import com.instabug.library.extendedbugreport.ExtendedBugReport;
1011

1112
import java.util.HashMap;
1213
import java.util.Locale;
@@ -57,6 +58,8 @@ final class ArgsRegistry {
5758
registerInvocationModeArgs(ARGS);
5859
registerInvocationOptionsArgs(ARGS);
5960
registerCustomTextPlaceHolderKeysArgs(ARGS);
61+
registerInstabugReportTypesArgs(ARGS);
62+
registerInstabugExtendedBugReportModeArgs(ARGS);
6063
}
6164

6265
/**
@@ -125,77 +128,90 @@ static void registerColorThemeArgs(Map<String, Object> args) {
125128

126129
@VisibleForTesting
127130
static void registerInvocationModeArgs(Map<String, Object> args) {
128-
args.put("InvocationMode.BUG", BugReporting.ReportType.BUG);
129-
args.put("InvocationMode.FEEDBACK", BugReporting.ReportType.FEEDBACK);
131+
args.put("InvocationMode.bug", BugReporting.ReportType.BUG);
132+
args.put("InvocationMode.feedback", BugReporting.ReportType.FEEDBACK);
130133
}
131134

132135
@VisibleForTesting
133136
static void registerInvocationOptionsArgs(Map<String, Object> args) {
134-
args.put("InvocationOption.COMMENT_FIELD_REQUIRED", Option.COMMENT_FIELD_REQUIRED);
135-
args.put("InvocationOption.DISABLE_POST_SENDING_DIALOG", Option.DISABLE_POST_SENDING_DIALOG);
136-
args.put("InvocationOption.EMAIL_FIELD_HIDDEN", Option.EMAIL_FIELD_HIDDEN);
137-
args.put("InvocationOption.EMAIL_FIELD_OPTIONAL", Option.EMAIL_FIELD_OPTIONAL);
137+
args.put("InvocationOption.commentFieldRequired", Option.COMMENT_FIELD_REQUIRED);
138+
args.put("InvocationOption.disablePostSendingDialog", Option.DISABLE_POST_SENDING_DIALOG);
139+
args.put("InvocationOption.emailFieldHidden", Option.EMAIL_FIELD_HIDDEN);
140+
args.put("InvocationOption.emailFieldOptional", Option.EMAIL_FIELD_OPTIONAL);
138141
}
139142

140143
@VisibleForTesting
141144
static void registerLocaleArgs(Map<String, Object> args) {
142-
args.put("Locale.ChineseTraditional", new Locale(TRADITIONAL_CHINESE.getCode(), TRADITIONAL_CHINESE.getCountry()));
143-
args.put("Locale.PortuguesePortugal", new Locale(PORTUGUESE_PORTUGAL.getCode(), PORTUGUESE_PORTUGAL.getCountry()));
144-
args.put("Locale.ChineseSimplified", new Locale(SIMPLIFIED_CHINESE.getCode(), SIMPLIFIED_CHINESE.getCountry()));
145-
args.put("Locale.PortugueseBrazil", new Locale(PORTUGUESE_BRAZIL.getCode(), PORTUGUESE_BRAZIL.getCountry()));
146-
args.put("Locale.Indonesian", new Locale(INDONESIAN.getCode(), INDONESIAN.getCountry()));
147-
args.put("Locale.Dutch", new Locale(NETHERLANDS.getCode(), NETHERLANDS.getCountry()));
148-
args.put("Locale.Norwegian", new Locale(NORWEGIAN.getCode(), NORWEGIAN.getCountry()));
149-
args.put("Locale.Japanese", new Locale(JAPANESE.getCode(), JAPANESE.getCountry()));
150-
args.put("Locale.English", new Locale(ENGLISH.getCode(), ENGLISH.getCountry()));
151-
args.put("Locale.Italian", new Locale(ITALIAN.getCode(), ITALIAN.getCountry()));
152-
args.put("Locale.Russian", new Locale(RUSSIAN.getCode(), RUSSIAN.getCountry()));
153-
args.put("Locale.Spanish", new Locale(SPANISH.getCode(), SPANISH.getCountry()));
154-
args.put("Locale.Swedish", new Locale(SWEDISH.getCode(), SWEDISH.getCountry()));
155-
args.put("Locale.Turkish", new Locale(TURKISH.getCode(), TURKISH.getCountry()));
156-
args.put("Locale.Arabic", new Locale(ARABIC.getCode(), ARABIC.getCountry()));
157-
args.put("Locale.Danish", new Locale(DANISH.getCode(), DANISH.getCountry()));
158-
args.put("Locale.French", new Locale(FRENCH.getCode(), FRENCH.getCountry()));
159-
args.put("Locale.German", new Locale(GERMAN.getCode(), GERMAN.getCountry()));
160-
args.put("Locale.Korean", new Locale(KOREAN.getCode(), KOREAN.getCountry()));
161-
args.put("Locale.Polish", new Locale(POLISH.getCode(), POLISH.getCountry()));
162-
args.put("Locale.Slovak", new Locale(SLOVAK.getCode(), SLOVAK.getCountry()));
163-
args.put("Locale.Czech", new Locale(CZECH.getCode(), CZECH.getCountry()));
145+
args.put("Locale.chineseTraditional", new Locale(TRADITIONAL_CHINESE.getCode(), TRADITIONAL_CHINESE.getCountry()));
146+
args.put("Locale.portuguesePortugal", new Locale(PORTUGUESE_PORTUGAL.getCode(), PORTUGUESE_PORTUGAL.getCountry()));
147+
args.put("Locale.chineseSimplified", new Locale(SIMPLIFIED_CHINESE.getCode(), SIMPLIFIED_CHINESE.getCountry()));
148+
args.put("Locale.portugueseBrazil", new Locale(PORTUGUESE_BRAZIL.getCode(), PORTUGUESE_BRAZIL.getCountry()));
149+
args.put("Locale.indonesian", new Locale(INDONESIAN.getCode(), INDONESIAN.getCountry()));
150+
args.put("Locale.dutch", new Locale(NETHERLANDS.getCode(), NETHERLANDS.getCountry()));
151+
args.put("Locale.norwegian", new Locale(NORWEGIAN.getCode(), NORWEGIAN.getCountry()));
152+
args.put("Locale.japanese", new Locale(JAPANESE.getCode(), JAPANESE.getCountry()));
153+
args.put("Locale.english", new Locale(ENGLISH.getCode(), ENGLISH.getCountry()));
154+
args.put("Locale.italian", new Locale(ITALIAN.getCode(), ITALIAN.getCountry()));
155+
args.put("Locale.russian", new Locale(RUSSIAN.getCode(), RUSSIAN.getCountry()));
156+
args.put("Locale.spanish", new Locale(SPANISH.getCode(), SPANISH.getCountry()));
157+
args.put("Locale.swedish", new Locale(SWEDISH.getCode(), SWEDISH.getCountry()));
158+
args.put("Locale.turkish", new Locale(TURKISH.getCode(), TURKISH.getCountry()));
159+
args.put("Locale.arabic", new Locale(ARABIC.getCode(), ARABIC.getCountry()));
160+
args.put("Locale.danish", new Locale(DANISH.getCode(), DANISH.getCountry()));
161+
args.put("Locale.french", new Locale(FRENCH.getCode(), FRENCH.getCountry()));
162+
args.put("Locale.german", new Locale(GERMAN.getCode(), GERMAN.getCountry()));
163+
args.put("Locale.korean", new Locale(KOREAN.getCode(), KOREAN.getCountry()));
164+
args.put("Locale.polish", new Locale(POLISH.getCode(), POLISH.getCountry()));
165+
args.put("Locale.slovak", new Locale(SLOVAK.getCode(), SLOVAK.getCountry()));
166+
args.put("Locale.czech", new Locale(CZECH.getCode(), CZECH.getCountry()));
164167
}
165168

166169
@VisibleForTesting
167170
static void registerCustomTextPlaceHolderKeysArgs(Map<String, Object> args) {
168-
args.put("IBGCustomTextPlaceHolderKey.SHAKE_HINT", InstabugCustomTextPlaceHolder.Key.SHAKE_HINT);
169-
args.put("IBGCustomTextPlaceHolderKey.SWIPE_HINT", InstabugCustomTextPlaceHolder.Key.SWIPE_HINT);
170-
args.put("IBGCustomTextPlaceHolderKey.INVALID_EMAIL_MESSAGE", InstabugCustomTextPlaceHolder.Key.INVALID_EMAIL_MESSAGE);
171-
args.put("IBGCustomTextPlaceHolderKey.INVALID_COMMENT_MESSAGE", InstabugCustomTextPlaceHolder.Key.INVALID_COMMENT_MESSAGE);
172-
args.put("IBGCustomTextPlaceHolderKey.INVOCATION_HEADER", InstabugCustomTextPlaceHolder.Key.INVOCATION_HEADER);
173-
args.put("IBGCustomTextPlaceHolderKey.START_CHATS", InstabugCustomTextPlaceHolder.Key.START_CHATS);
174-
args.put("IBGCustomTextPlaceHolderKey.REPORT_BUG", InstabugCustomTextPlaceHolder.Key.REPORT_BUG);
175-
args.put("IBGCustomTextPlaceHolderKey.REPORT_FEEDBACK", InstabugCustomTextPlaceHolder.Key.REPORT_FEEDBACK);
176-
args.put("IBGCustomTextPlaceHolderKey.EMAIL_FIELD_HINT", InstabugCustomTextPlaceHolder.Key.EMAIL_FIELD_HINT);
177-
args.put("IBGCustomTextPlaceHolderKey.COMMENT_FIELD_HINT_FOR_BUG_REPORT", InstabugCustomTextPlaceHolder.Key.COMMENT_FIELD_HINT_FOR_BUG_REPORT);
178-
args.put("IBGCustomTextPlaceHolderKey.COMMENT_FIELD_HINT_FOR_FEEDBACK", InstabugCustomTextPlaceHolder.Key.COMMENT_FIELD_HINT_FOR_FEEDBACK);
179-
args.put("IBGCustomTextPlaceHolderKey.ADD_VOICE_MESSAGE", InstabugCustomTextPlaceHolder.Key.ADD_VOICE_MESSAGE);
180-
args.put("IBGCustomTextPlaceHolderKey.ADD_IMAGE_FROM_GALLERY", InstabugCustomTextPlaceHolder.Key.ADD_IMAGE_FROM_GALLERY);
181-
args.put("IBGCustomTextPlaceHolderKey.ADD_EXTRA_SCREENSHOT", InstabugCustomTextPlaceHolder.Key.ADD_EXTRA_SCREENSHOT);
182-
args.put("IBGCustomTextPlaceHolderKey.CONVERSATIONS_LIST_TITLE", InstabugCustomTextPlaceHolder.Key.CONVERSATIONS_LIST_TITLE);
183-
args.put("IBGCustomTextPlaceHolderKey.AUDIO_RECORDING_PERMISSION_DENIED", InstabugCustomTextPlaceHolder.Key.AUDIO_RECORDING_PERMISSION_DENIED);
184-
args.put("IBGCustomTextPlaceHolderKey.CONVERSATION_TEXT_FIELD_HINT", InstabugCustomTextPlaceHolder.Key.CONVERSATION_TEXT_FIELD_HINT);
185-
args.put("IBGCustomTextPlaceHolderKey.BUG_REPORT_HEADER", InstabugCustomTextPlaceHolder.Key.BUG_REPORT_HEADER);
186-
args.put("IBGCustomTextPlaceHolderKey.FEEDBACK_REPORT_HEADER", InstabugCustomTextPlaceHolder.Key.FEEDBACK_REPORT_HEADER);
187-
args.put("IBGCustomTextPlaceHolderKey.VOICE_MESSAGE_PRESS_AND_HOLD_TO_RECORD", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_PRESS_AND_HOLD_TO_RECORD);
188-
args.put("IBGCustomTextPlaceHolderKey.VOICE_MESSAGE_RELEASE_TO_ATTACH", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_RELEASE_TO_ATTACH);
189-
args.put("IBGCustomTextPlaceHolderKey.REPORT_SUCCESSFULLY_SENT", InstabugCustomTextPlaceHolder.Key.REPORT_SUCCESSFULLY_SENT);
190-
args.put("IBGCustomTextPlaceHolderKey.SUCCESS_DIALOG_HEADER", InstabugCustomTextPlaceHolder.Key.SUCCESS_DIALOG_HEADER);
191-
args.put("IBGCustomTextPlaceHolderKey.ADD_VIDEO", InstabugCustomTextPlaceHolder.Key.ADD_VIDEO);
192-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_WELCOME_STEP_TITLE", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_WELCOME_STEP_TITLE);
193-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_WELCOME_STEP_CONTENT", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_WELCOME_STEP_CONTENT);
194-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_TITLE", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_TITLE);
195-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_CONTENT", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_CONTENT);
196-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_FINISH_STEP_TITLE", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_FINISH_STEP_TITLE);
197-
args.put("IBGCustomTextPlaceHolderKey.BETA_WELCOME_MESSAGE_FINISH_STEP_CONTENT", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_FINISH_STEP_CONTENT);
198-
args.put("IBGCustomTextPlaceHolderKey.LIVE_WELCOME_MESSAGE_TITLE", InstabugCustomTextPlaceHolder.Key.LIVE_WELCOME_MESSAGE_TITLE);
199-
args.put("IBGCustomTextPlaceHolderKey.LIVE_WELCOME_MESSAGE_CONTENT", InstabugCustomTextPlaceHolder.Key.LIVE_WELCOME_MESSAGE_CONTENT);
171+
args.put("IBGCustomTextPlaceHolderKey.shakeHint", InstabugCustomTextPlaceHolder.Key.SHAKE_HINT);
172+
args.put("IBGCustomTextPlaceHolderKey.swipeHint", InstabugCustomTextPlaceHolder.Key.SWIPE_HINT);
173+
args.put("IBGCustomTextPlaceHolderKey.invalidEmailMessage", InstabugCustomTextPlaceHolder.Key.INVALID_EMAIL_MESSAGE);
174+
args.put("IBGCustomTextPlaceHolderKey.invalidCommentMessage", InstabugCustomTextPlaceHolder.Key.INVALID_COMMENT_MESSAGE);
175+
args.put("IBGCustomTextPlaceHolderKey.invocationHeader", InstabugCustomTextPlaceHolder.Key.INVOCATION_HEADER);
176+
args.put("IBGCustomTextPlaceHolderKey.startChats", InstabugCustomTextPlaceHolder.Key.START_CHATS);
177+
args.put("IBGCustomTextPlaceHolderKey.reportBug", InstabugCustomTextPlaceHolder.Key.REPORT_BUG);
178+
args.put("IBGCustomTextPlaceHolderKey.reportFeedback", InstabugCustomTextPlaceHolder.Key.REPORT_FEEDBACK);
179+
args.put("IBGCustomTextPlaceHolderKey.emailFieldHint", InstabugCustomTextPlaceHolder.Key.EMAIL_FIELD_HINT);
180+
args.put("IBGCustomTextPlaceHolderKey.commentFieldHintForBugReport", InstabugCustomTextPlaceHolder.Key.COMMENT_FIELD_HINT_FOR_BUG_REPORT);
181+
args.put("IBGCustomTextPlaceHolderKey.commentFieldHintForFeedback", InstabugCustomTextPlaceHolder.Key.COMMENT_FIELD_HINT_FOR_FEEDBACK);
182+
args.put("IBGCustomTextPlaceHolderKey.addVoiceMessage", InstabugCustomTextPlaceHolder.Key.ADD_VOICE_MESSAGE);
183+
args.put("IBGCustomTextPlaceHolderKey.addImageFromGallery", InstabugCustomTextPlaceHolder.Key.ADD_IMAGE_FROM_GALLERY);
184+
args.put("IBGCustomTextPlaceHolderKey.addExtraScreenshot", InstabugCustomTextPlaceHolder.Key.ADD_EXTRA_SCREENSHOT);
185+
args.put("IBGCustomTextPlaceHolderKey.conversationsListTitle", InstabugCustomTextPlaceHolder.Key.CONVERSATIONS_LIST_TITLE);
186+
args.put("IBGCustomTextPlaceHolderKey.audioRecordingPermissionDenied", InstabugCustomTextPlaceHolder.Key.AUDIO_RECORDING_PERMISSION_DENIED);
187+
args.put("IBGCustomTextPlaceHolderKey.conversationTextFieldHint", InstabugCustomTextPlaceHolder.Key.CONVERSATION_TEXT_FIELD_HINT);
188+
args.put("IBGCustomTextPlaceHolderKey.bugReportHeader", InstabugCustomTextPlaceHolder.Key.BUG_REPORT_HEADER);
189+
args.put("IBGCustomTextPlaceHolderKey.feedbackReportHeader", InstabugCustomTextPlaceHolder.Key.FEEDBACK_REPORT_HEADER);
190+
args.put("IBGCustomTextPlaceHolderKey.voiceMessagePressAndHoldToRecord", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_PRESS_AND_HOLD_TO_RECORD);
191+
args.put("IBGCustomTextPlaceHolderKey.voiceMessageReleaseToAttach", InstabugCustomTextPlaceHolder.Key.VOICE_MESSAGE_RELEASE_TO_ATTACH);
192+
args.put("IBGCustomTextPlaceHolderKey.reportSuccessfullySent", InstabugCustomTextPlaceHolder.Key.REPORT_SUCCESSFULLY_SENT);
193+
args.put("IBGCustomTextPlaceHolderKey.successDialogHeader", InstabugCustomTextPlaceHolder.Key.SUCCESS_DIALOG_HEADER);
194+
args.put("IBGCustomTextPlaceHolderKey.addVideo", InstabugCustomTextPlaceHolder.Key.ADD_VIDEO);
195+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageWelcomeStepTitle", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_WELCOME_STEP_TITLE);
196+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageWelcomeStepContent", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_WELCOME_STEP_CONTENT);
197+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageHowToReportStepTitle", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_TITLE);
198+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageHowToReportStepContent", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_HOW_TO_REPORT_STEP_CONTENT);
199+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageFinishStepTitle", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_FINISH_STEP_TITLE);
200+
args.put("IBGCustomTextPlaceHolderKey.betaWelcomeMessageFinishStepContent", InstabugCustomTextPlaceHolder.Key.BETA_WELCOME_MESSAGE_FINISH_STEP_CONTENT);
201+
args.put("IBGCustomTextPlaceHolderKey.liveWelcomeMessageTitle", InstabugCustomTextPlaceHolder.Key.LIVE_WELCOME_MESSAGE_TITLE);
202+
args.put("IBGCustomTextPlaceHolderKey.liveWelcomeMessageContent", InstabugCustomTextPlaceHolder.Key.LIVE_WELCOME_MESSAGE_CONTENT);
203+
}
204+
205+
@VisibleForTesting
206+
static void registerInstabugReportTypesArgs(Map<String, Object> args) {
207+
args.put("ReportType.bug", BugReporting.ReportType.BUG);
208+
args.put("ReportType.feedback", BugReporting.ReportType.FEEDBACK);
209+
}
210+
211+
@VisibleForTesting
212+
static void registerInstabugExtendedBugReportModeArgs(Map<String, Object> args) {
213+
args.put("ExtendedBugReportMode.enabledWithRequiredFields", ExtendedBugReport.State.ENABLED_WITH_REQUIRED_FIELDS);
214+
args.put("ExtendedBugReportMode.enabledWithOptionalFields", ExtendedBugReport.State.ENABLED_WITH_OPTIONAL_FIELDS);
215+
args.put("ExtendedBugReportMode.disabled",ExtendedBugReport.State.DISABLED);
200216
}
201217
}

0 commit comments

Comments
 (0)