Test Suite

Test Suite

The OpenMediation Test Suite allows you to test whether you have correctly configured your app and ad units to be able to display ads from third-party networks through mediation. This guide outlines how to use the OpenMediation Test Suite in your Android app by integrating the tool into your app.

 

Precondition

1. Android SDK 4.1 (API level 16) or higher.

2. Android OpenMediation SDK v2.0.0 or higher.

3. Create an OpenMediation account and register an app.

 

Installation

Add the following dependencies to the project-level build.gradle file:

allprojects {
    repositories {
        google()
        jcenter()
        maven { url 'https://dl.openmediation.com/omcenter/' }
    }
}

 

Add the following dependencies into your apps build.gradle file:

android {
   compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
}

dependencies {
    implementation 'com.openmediation:om-android-sdk:+'
    implementation 'com.openmediation:test-suite:1.3.0'
}

 

Proguard

If you need to use proguard to optimize the code, please add the following configuration to the proguard.cfg file (or other replacement files):

-dontwarn com.openmediation.testsuite.**
-keep class com.openmediation.testsuite.**{*;}

 

Launching the Test Suite

Use the following line of code to launch the Mediation Test Suite:

import com.openmediation.testsuite.TestSuite;
...
TestSuite.launch(activity, appKey);

Note: Please remove the dependencies and code references of TestSuite before your application goes live.

 

Navigating the Test Suite

The tool opens with the following disclaimer:

device-2020-12-23-201551.png

The disclaimer shows every time the test suite launches as a reminder that you should turn on test mode for your mediation ad sources.

 

Tick the checkbox and press GOT IT to proceed.

The homepage will show the Ad Network integration status of your current application.

Each Ad Network has three configurations, including SDK/Adapter/Configure.

For each Ad Network, this screen provides warnings if:

  • An ad source SDK is not installed
  • An ad source adapter is not installed
  • An ad source requires manifest entries that are not configured or the background configuration information is incorrect.

device-2020-12-23-201713.png

 

If the three configurations of all Ad Networks are okay, the homepage will display "Good", as shown below:

device-2020-12-23-201604.png

 

If you verify the instance of Ad Network and it fails, the home page will display the number of failed instances. At the same time, the corresponding Ad Network Instance will show a yellow prompt.

device-2020-12-23-202333.png

 

Ad Network Details

The details page displays the detailed information of Ad Network, including the integration status STATUS of Ad Network, TEST ID list (only AdMob) and INSTANCE list:

device-2020-12-24-191317.png

 

STATUS

The screen indicates, for the given ad source:

  • If the SDK is installed and, if available, the SDK version (Some AdNetwork SDK version cannot be obtained, such as AdMob and AdColony).
  • If the adapter is installed and, if available, the adapter version.
  • If any required manifest entries are properly configured.
  • The parameters for the configuration that were entered in the OpenMediation dashboard.

 

INSTANCE

The INSTANCE list page lists all the Instances configured in the foreground of the Ad Network in the "Enabled" state, and distinguishes 3 states by different colors:

  • Not verified (Blue)
  • Ad verified but failed to load (Yellow)
  • The ad has been verified and successfully loaded (Green)

The information displayed by a single Instance Item includes:

  • Instance Name
  • Unit ID
  • Instance belongs to the type of ad unit
  • Instance belongs to the name of ad unit

device-2020-12-23-202600.png

 

FILTER

You can filter Instance results according to Instance status and ad type on the filter page.

android_instance_filter.png

 

Load And Show Ad

On the TESTID and INSTANCE list page, click the "LOAD AD" button to send the ad request to the SDK of the ad source. After the ad request is completed, an update prompt will be displayed, indicating whether the request was successful or failed.

device-2020-12-23-202639.png

 

If the request is successful, the "LOAD AD" button will change to "SHOW AD", and there will be a Success prompt on the page.

  • For banner or native ads, the ad is displayed directly on the current page.
  • For interstitial or rewarded video ads, the ad will be displayed on the new screen.

device-2020-12-23-202650.png

 

The ad opens on the current page, for example:

device-2020-12-23-202706.png

 

The ad opens in a new screen, for example:

android_instance_show_is.png

 

Data Reporting

device-12-24.png

After clicking the upload button, your AdNetwork integration results and Instance verification results will be uploaded to the OpenMediation dashboard - SDK Testing - Test Suite Result, For more information.

test-suite-result.jpeg

Note: Test results are only stored in memory for a given app. They are not stored on the device.

 

 

Was this article helpful?
3 out of 3 found this helpful

Comments

0 comments

Article is closed for comments.