From 13470ee7c4fa38f1bed386af14de6c5d8ec9b4db Mon Sep 17 00:00:00 2001 From: Mike Hardy Date: Fri, 8 Apr 2022 13:54:55 -0500 Subject: [PATCH 1/7] chore(test, typo): Rewared -> Rewarded --- example/App.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/example/App.tsx b/example/App.tsx index 7af60886..8baa1222 100644 --- a/example/App.tsx +++ b/example/App.tsx @@ -155,7 +155,7 @@ const rewarded = RewardedAd.createForAdRequest(rewardedAdUnitId, { requestNonPersonalizedAdsOnly: true, keywords: ['fashion', 'clothing'], }); -class RewaredTest implements Test { +class RewardedTest implements Test { constructor() { rewarded.load(); } @@ -291,7 +291,7 @@ class HookTest implements Test { TestRegistry.registerTest(new BannerTest()); TestRegistry.registerTest(new AppOpenTest()); TestRegistry.registerTest(new InterstitialTest()); -TestRegistry.registerTest(new RewaredTest()); +TestRegistry.registerTest(new RewardedTest()); TestRegistry.registerTest(new AdConsentTest()); TestRegistry.registerTest(new HookTest()); From b04ec76bb54fc10fee6c820914ae5c3ad0b86f1e Mon Sep 17 00:00:00 2001 From: Mike Hardy Date: Fri, 8 Apr 2022 14:00:56 -0500 Subject: [PATCH 2/7] chore(test): test paths are not supposed to have spaces Of course that's not documented anywhere in jet-next, apologies --- example/App.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/example/App.tsx b/example/App.tsx index 8baa1222..2ef708ba 100644 --- a/example/App.tsx +++ b/example/App.tsx @@ -34,7 +34,7 @@ class AppOpenTest implements Test { } getPath(): string { - return 'App open'; + return 'AppOpen'; } getTestType(): TestType { @@ -195,7 +195,7 @@ class RewardedTest implements Test { class AdConsentTest implements Test { getPath(): string { - return 'Consent Form'; + return 'ConsentForm'; } getTestType(): TestType { From ffa18ba57275d7d77b33c4a083b97fea527c50f8 Mon Sep 17 00:00:00 2001 From: Mike Hardy Date: Fri, 8 Apr 2022 14:01:37 -0500 Subject: [PATCH 3/7] test(hooks): rename HookTest to InterstitialHookTest, check load status --- example/App.tsx | 14 ++++++++------ example/ios/Podfile.lock | 4 ++-- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/example/App.tsx b/example/App.tsx index 2ef708ba..c56c5cee 100644 --- a/example/App.tsx +++ b/example/App.tsx @@ -245,15 +245,17 @@ class AdConsentTest implements Test { } } -const HookComponent = React.forwardRef((_, ref) => { - const {load, show} = useInterstitialAd(TestIds.INTERSTITIAL); +const InterstitialHookComponent = React.forwardRef((_, ref) => { + const {load, show, isLoaded} = useInterstitialAd(TestIds.INTERSTITIAL); useEffect(() => { load(); }, [load]); return ( + Loaded? {isLoaded ? 'true' : 'false'}