@Test public void getRemainingScansStream() { final BehaviorSubject<Integer> scansStream = BehaviorSubject.createDefault(50); when(localOcrScansTracker.getRemainingScansStream()).thenReturn(scansStream); ocrPurchaseTracker.getRemainingScansStream().test() .assertValue(50) .assertNotComplete() .assertNoErrors(); }
public Observable<Integer> getRemainingScansStream() { return localOcrScansTracker.getRemainingScansStream(); }
OcrPurchaseTracker implements PurchaseEventsListener { public Observable<Integer> getRemainingScansStream() { return localOcrScansTracker.getRemainingScansStream(); } }
OcrPurchaseTracker implements PurchaseEventsListener { public Observable<Integer> getRemainingScansStream() { return localOcrScansTracker.getRemainingScansStream(); } @Inject  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                              @NonNull WebServiceManager webServiceManager,
                              @NonNull PurchaseManager purchaseManager,
                              @NonNull PurchaseWallet purchaseWallet,
                              @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                              @NonNull LocalOcrScansTracker localOcrScansTracker); @VisibleForTesting  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                       @NonNull WebServiceManager webServiceManager,
                       @NonNull PurchaseManager purchaseManager,
                       @NonNull PurchaseWallet purchaseWallet,
                       @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                       @NonNull LocalOcrScansTracker localOcrScansTracker,
                       @NonNull Scheduler subscribeOnScheduler); }
OcrPurchaseTracker implements PurchaseEventsListener { public Observable<Integer> getRemainingScansStream() { return localOcrScansTracker.getRemainingScansStream(); } @Inject  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                              @NonNull WebServiceManager webServiceManager,
                              @NonNull PurchaseManager purchaseManager,
                              @NonNull PurchaseWallet purchaseWallet,
                              @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                              @NonNull LocalOcrScansTracker localOcrScansTracker); @VisibleForTesting  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                       @NonNull WebServiceManager webServiceManager,
                       @NonNull PurchaseManager purchaseManager,
                       @NonNull PurchaseWallet purchaseWallet,
                       @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                       @NonNull LocalOcrScansTracker localOcrScansTracker,
                       @NonNull Scheduler subscribeOnScheduler); @SuppressLint("CheckResult") void initialize(); @Override void onPurchaseSuccess(@NonNull InAppPurchase inAppPurchase, @NonNull PurchaseSource purchaseSource); @Override void onPurchaseFailed(@NonNull PurchaseSource purchaseSource); int getRemainingScans(); Observable<Integer> getRemainingScansStream(); boolean hasAvailableScans(); void decrementRemainingScans(); }
OcrPurchaseTracker implements PurchaseEventsListener { public Observable<Integer> getRemainingScansStream() { return localOcrScansTracker.getRemainingScansStream(); } @Inject  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                              @NonNull WebServiceManager webServiceManager,
                              @NonNull PurchaseManager purchaseManager,
                              @NonNull PurchaseWallet purchaseWallet,
                              @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                              @NonNull LocalOcrScansTracker localOcrScansTracker); @VisibleForTesting  OcrPurchaseTracker(@NonNull IdentityManager identityManager,
                       @NonNull WebServiceManager webServiceManager,
                       @NonNull PurchaseManager purchaseManager,
                       @NonNull PurchaseWallet purchaseWallet,
                       @NonNull DefaultInAppPurchaseConsumer defaultInAppPurchaseConsumer,
                       @NonNull LocalOcrScansTracker localOcrScansTracker,
                       @NonNull Scheduler subscribeOnScheduler); @SuppressLint("CheckResult") void initialize(); @Override void onPurchaseSuccess(@NonNull InAppPurchase inAppPurchase, @NonNull PurchaseSource purchaseSource); @Override void onPurchaseFailed(@NonNull PurchaseSource purchaseSource); int getRemainingScans(); Observable<Integer> getRemainingScansStream(); boolean hasAvailableScans(); void decrementRemainingScans();  }