تست واحدهای تبلیغاتی
با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
پلتفرم را انتخاب کنید: Android iOS Unity Flutter Ad Inspector از تست های زیر پشتیبانی می کند:
- تست درون متنی : تبلیغات را از واحدهای تبلیغاتی در برنامه خود بارگیری کنید. میتوانید برای مشاهده جزئیات درخواستهای ارائهشده از واحدهای تبلیغاتی، بازرس آگهی را باز کنید.
- آزمایش خارج از زمینه : واحد تبلیغات خود را مستقیماً در بازرس آگهی بدون پیمایش به رابط کاربری برنامه خود آزمایش کنید. میتوانید چندین واحد تبلیغاتی را بهطور همزمان آزمایش کنید، درخواستهای آگهی آزمایشی خود را بهصورت ناهمزمان بارگیری و مشاهده کنید، و آزمایشهای منبع آگهی را انجام دهید.
هنگام اجرای یک آزمایش خارج از زمینه، درخواستهای شما دارای پارامترهایی برای اجرا در رابط کاربری برنامه شما نیستند، از جمله پیکربندی درمان هدایتشده توسط کودک، هدفگیری سفارشی، امکانات اضافی شبکه و اندازههای مختلف. با توجه به محدودیت این درخواستها، توصیه میکنیم از تست درون متنی در رابط کاربری برنامه خود استفاده کنید.
پیش نیازها
قبل از ادامه، موارد زیر را انجام دهید:
- همه موارد موجود در پیش نیازهای اولیه را تکمیل کنید تا یک حساب AdMob ایجاد کنید، دستگاه آزمایشی خود را تنظیم کنید، SDK تبلیغات تلفن همراه Google را مقداردهی اولیه کنید و آخرین نسخه را نصب کنید.
- بازرس آگهی را راه اندازی کنید .
درخواست آگهی آزمایشی
برای درخواست آگهی آزمایشی در ad inspector مراحل زیر را انجام دهید. برای جزئیات بیشتر، نحوه استفاده از بازرس آگهی در برنامه خود را ببینید.
درون زمینه :
- در یک دستگاه آزمایشی، به رابط کاربری برنامه خود بروید و یک آگهی بارگیری کنید.
- بازرس آگهی را باز کنید. در تب واحد آگهی ، واحد تبلیغاتی را که آگهی را در آن بارگذاری کردهاید، بیابید.
- در گزارش درخواست SDK ، جزئیات آگهی آزمایشی درخواستی خود را مشاهده کنید.
خارج از زمینه :
- در برگه واحد آگهی ، روی واحد آگهی خود ضربه بزنید و روی درخواست آگهی آزمایشی کلیک کنید.
- در گزارش درخواست SDK ، جزئیات آگهی آزمایشی درخواستی خود را مشاهده کنید.

اگر قالب واحد تبلیغات ناشناخته را نشان دهد، میبینید درخواست آگهی آزمایشی خاکستری شده است.
یک منبع آگهی را آزمایش کنید
بازرس آگهی میتواند درخواستهای تبلیغات را در برنامه شما محدود کند تا تبلیغات را از یک منبع آگهی مناقصه یا آبشاری ارائه کند. این رویکرد به شما امکان میدهد تأیید کنید که به درستی با آداپتور شخص ثالث ادغام شدهاید و منبع آگهی همانطور که انتظار میرود عمل میکند.
برای آزمایش یک منبع تبلیغاتی، مراحل زیر را انجام دهید:
در Ad inspector ، روی دکمه تست منبع آگهی تک کلیک کنید. یک گفتگوی آزمایشی منبع آگهی منفرد ظاهر می شود:

یک منبع تبلیغ را برای آزمایش انتخاب کنید. پس از آن، صفحه برنامه راهاندازی مجدد نیرو را دریافت میکنید:

تنظیم آزمایش منبع تک آگهی برای هر درخواست آگهی آتی که ارائه میکنید اعمال میشود. این آزمایش برای تبلیغات ذخیره شده قبلی در آن جلسه اعمال نمی شود. ما به شما توصیه می کنیم هنگام استفاده از یک آزمایش منبع تبلیغاتی، برنامه خود را مجدداً راه اندازی کنید. این رویکرد، آگهیهای ذخیرهشده در حافظه پنهان را که ممکن است به جای اینکه منبع آگهی انتخابی شما درخواستی دریافت کند، نمایش داده میشود، بیاعتبار میکند.
پس از راهاندازی مجدد برنامه، همه مکانهای واحد تبلیغات سعی میکنند آگهی را از منبع آگهی انتخابشده نشان دهند. راهاندازی بازرس آگهی زمانی که یک آزمایش منبع آگهی واحد فعال است، منبع آگهی آزمایشی فعال را نشان میدهد:

در حالت آزمایش منبع آگهی، همه درخواستهای آگهی سعی میکنند با منبع آگهی انتخابشده پر شوند، صرف نظر از اینکه آن منبع آگهی برای مناقصه یا آبشار پیکربندی شده است. اگر منبع تبلیغی که آزمایش میکنید برای مناقصه یا آبشار برای واحد تبلیغات تنظیم نشده باشد، پیام خطای زیر را دریافت میکنید:
Ad Unit has no applicable adapter for single ad source testing on network: AD_SOURCE_ADAPTER_CLASS_NAME
برای تأیید اینکه آیا منبع آگهی درخواستهای آگهی را پس از شروع آزمایش منبع آگهی تکمیل کرده است یا خیر، روی یک واحد تبلیغات ضربه بزنید تا گزارش درخواست SDK را مشاهده کنید. اگر منبع آگهی نتوانست تبلیغی را بارگیری کند، پیام خطایی ظاهر میشود که خطا را توصیف میکند، مانند Adapter failed to initialize
.
اگر چندین نمونه از منبع تبلیغات انتخابی را به یک آبشار اضافه کرده باشید، هر نمونه تماس را به منبع تبلیغ میبینید. این فرآیند تا زمانی که آگهی پر شود یا آبشار بدون پر شود رندر می شود.
یک آزمایش منبع آگهی را متوقف کنید
برای توقف آزمایش، مراحل زیر را انجام دهید:
- در Ad inspector ، روی دکمه تست منبع آگهی تک کلیک کنید. تست منبع تک آگهی توقف؟ گفتگو ظاهر می شود
روی Stop test ضربه بزنید.

در صورت موفقیت آمیز بودن، یک پیام تأیید روی برنامه راه اندازی مجدد اجباری ظاهر می شود:

برای لغو آگهیهای ذخیرهشده برای منبع آگهی آزمایششده، توصیه میکنیم پس از توقف آزمایش، برنامه را اجباری مجدداً راهاندازی کنید.
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-09-06 بهوقت ساعت هماهنگ جهانی.
[[["درک آسان","easyToUnderstand","thumb-up"],["مشکلم را برطرف کرد","solvedMyProblem","thumb-up"],["غیره","otherUp","thumb-up"]],[["اطلاعاتی که نیاز دارم وجود ندارد","missingTheInformationINeed","thumb-down"],["بیشازحد پیچیده/ مراحل بسیار زیاد","tooComplicatedTooManySteps","thumb-down"],["قدیمی","outOfDate","thumb-down"],["مشکل ترجمه","translationIssue","thumb-down"],["مشکل کد / نمونهها","samplesCodeIssue","thumb-down"],["غیره","otherDown","thumb-down"]],["تاریخ آخرین بهروزرسانی 2025-09-06 بهوقت ساعت هماهنگ جهانی."],[],[],null,["Select platform: [Android](/admob/android/ad-inspector/test-ad-units \"View this page for the Android platform docs.\") [iOS](/admob/ios/ad-inspector/test-ad-units \"View this page for the iOS platform docs.\") [Unity](/admob/unity/ad-inspector/test-ad-units \"View this page for the Unity platform docs.\") [Flutter](/admob/flutter/ad-inspector/test-ad-units \"View this page for the Flutter platform docs.\")\n\n\u003cbr /\u003e\n\nAd inspector supports the following tests:\n\n- **In-context testing**: load ads from the ad units in your app. You can open ad inspector to view details on requests made from ad units.\n- **Out-of-context testing**: test your ad unit directly in ad inspector without navigating to your app's UI. You can test multiple ad units at once, asynchronously load and view your test ad requests, and perform single ad source tests.\n\nWhen running an out-of-context test, your requests don't carry the parameters\nto run in your app's UI, including child-directed treatment configuration,\ncustom targeting, network extras, and different sizes. Due to the limitation of\nthese requests, we recommend you use in-context testing in your app's UI.\n\nPrerequisites\n\nBefore you continue, do the following:\n\n- Complete all items in the initial [Prerequisites](/admob/android/ad-inspector#prerequisites) to create an AdMob account, set your test device, initialize Google Mobile Ads SDK, and install the latest version.\n- [Launch ad inspector](/admob/android/ad-inspector/launch-ad-inspector).\n\nRequest a test ad\n\nTo request a test ad in ad inspector, complete the following steps. For more\ndetails, see\n\n[How to use ad inspector in your app](//support.google.com/admob/answer/13063114).\n\n\n- **In-context**:\n\n 1. On a test device, navigate to your app's UI and load an ad.\n 2. Open ad inspector. In the **Ad unit** tab, find the ad unit where you loaded the ad.\n 3. In **SDK request log**, view details on your requested test ad.\n- **Out-of-context**:\n\n 1. In the **Ad unit** tab, tap on your ad unit and click **Request test ad**.\n 2. In **SDK request log**, view details on your requested test ad.\n\n| **Note:** To request a test ad, [initialize the Google Mobile Ads SDK](/admob/android/quick-start#initialize_the_mobile_ads_sdk) with an `Activity` context.\n\nIf the ad unit format shows **Unknown** , you see **Request test ad** greyed\nout.\n\nTest a single ad source\n\nAd inspector can restrict ad requests in your app to serve ads from a single\nbidding or waterfall ad source. This approach lets you verify that you've\ncorrectly integrated with the third-party adapter, and the ad source serves\nas expected.\n\nTo test a single ad source, complete the following steps:\n\n1. In **Ad inspector** , click the **Single ad source test** toggle. A\n **Single ad source test** dialog appears:\n\n\n2. Select an ad source to test. Afterwards, you receive the\n **Force restart app** page:\n\nThe single ad source test setting applies to any future ad requests you make.\nThis test doesn't apply to previously cached ads in that session.\nWe recommend you to force restarting your app when applying a single ad source\ntest. This approach invalidates cached ads that might display instead of\nyour chosen ad source receiving a request.\n\nAfter restarting your app, all ad unit placements attempt to show an ad from the\nselected ad source. Launching ad inspector when a single ad source test is\nactive shows the active test ad source:\n\nIn single ad source test mode, all ad requests attempt to fill with the\nselected ad source, regardless of whether that ad source was configured for\nbidding or waterfall. If the ad source you're testing is not set up for bidding\nor waterfall for the ad unit, you receive the following error message: \n\n Ad Unit has no applicable adapter for single ad source testing on network: \u003cvar translate=\"no\"\u003eAD_SOURCE_ADAPTER_CLASS_NAME\u003c/var\u003e\n\nTo verify whether the ad source filled the ad requests after you start a single\nad source test, tap an ad unit to view the SDK request log. If the ad source\nfailed to load an ad, an error message appears describing the error, such\nas `Adapter failed to initialize`.\n\nIf you've added multiple instances of the selected ad source to a waterfall, you\nsee each call instance to the ad source. This process renders until the ad is\neither filled or the waterfall ends without a fill.\n\nStop a single ad source test\n\nTo stop the test, complete the following steps:\n\n1. In **Ad inspector** , click off the **Single ad source test** toggle. The **Stop single ad source test?** dialog appears.\n2. Tap **Stop test**.\n\n\n If successful, a confirmation message appears over **Force restart app**:\n\nTo revoke cached ads for the tested ad source, we recommend you to force\nrestart the app after stopping the test."]]