checkAdsTest static method

dynamic checkAdsTest(
  1. String headline
)

Implementation

static checkAdsTest(String headline) {
  try {
    if (headline.isNotEmpty) {
      final testAdResponse = headline.replaceAll(" ", "").split(":")[0];
      debugPrint('===Native: $testAdResponse');

      const testAdResponses = [
        'TestAd',
        'Anunciodeprueba',
        'Annoncetest',
        '테스트광고',
        'Annuncioditesto',
        'Testanzeige',
        'TesIklan',
        'Anúnciodeteste',
        'Тестовоеобъявление',
        'পরীক্ষামূলকবিজ্ঞাপন',
        'जाँचविज्ञापन',
        'إعلانتجريبي',
        'Quảngcáothửnghiệm',
      ];
      isTestDevice = testAdResponses.contains(testAdResponse);
    }
  } catch (e) {
    isTestDevice = true;
    debugPrint('===Native: Error');
  }
}