This section shows you how to integrate qTest Mobile Explorer Agent to your application on iOS devices. These are the steps that you need to follow:
Step 1: Download Mobile Explorer Agent
Download Mobile Explorer Agent from HERE
Step 2: Add Mobile Explorer Agent to your project
Notes: In this guideline, we use iFixit as a sample project
- Extract the archived file
- Add Mobile_eXplorer_Agent folder to your project by right click on root of your project on Project Navigator and select “Add Files to "iFixit"”...
- In Add File dialog, make sure "Copy items if needed" option is checked and "Create groups" option is selected as well. Notes: "Create groups" option must be selected in order to successfully complile Mobile Explorer Agent for iOS
- The project structure in Xcode will look like this:
- To avoid effects on your current settings, we suggest you clone the active target for integration with Mobile Explorer Agent by right clicking on active targets and selecting “Duplicate” or pressing “CMD + D”. If you want to release your application to the App Store, just use an origin target.
- Select a target that you want to run with Mobile eXplorer Agent -> Go to “Build Settings” and type “Other” in search box and double click on “Other Linker Flags”
- Add 3 flags to “Other Linker Flags” if they are missing:
- On “Build Settings”, type “Preprocessor Macros” in search box and double click on “Preprocessor Macros”
- Add “MEXPLORER=1” to turn on Mobile Explorer Agent
Step 3: Enable Mobile Explorer Agent on your app
After adding Mobile Explorer Agent to your project (step 2), you need to enable Mobile Explorer Agent by below snip codes
For project that is using Objective-C language
- Import “MXExplorer.h” to on the top of Application Delegate (.m file)
#if MEXPLORER == 1
- Import these sample codes to inside the “didFinishLaunchingWithOptions” function. We recommend calling Mobile eXplorer Agent from the main thread, because Mobile eXplorer Agent is not supported when called from other threads
#if MEXPLORER == 1
MXExplorer *explorer = [MXExplorer sharedInstance];
explorer.theme = MXThemeLight;
The Mobile Explorer Agent supports 2 themes (Dark/Light). Please select the theme that is appropriate with your application. For example, if your application has light colors, you can select the dark theme.
- Select the target with integrated Mobile Explorer Agent
For project that is using Swift language
Step 4: Build and Release your application
After you’ve finished the 3 steps above, your final task is to Build and Release your application to the Tester.