Test mode Android

There is an option for loading test-only banners on certain device.

Add your test device

  1. Load your ads-integrated app and make an ad request.

  2. Check the logcat output for a message that looks like the one below, which shows you your device ID and how to add it as a test device:
D/[myTarget]: Device instanceId is aa5e068d-fdba-46f6-b84a-d1369e76de13. Use this value in adInstance.withTestDevices() to enable test mode on this device.
Copy your test device ID to your clipboard.

3. Modify your code to call ad.withTestDevices() and pass in a list of your test device IDs.
4. Re-run your app. Now the ad instances would receive test ad:
5. Be sure to remove the code that sets these test device IDs before you release your app.
Was this article helpful?