BackupProvidersManager implements BackupProvider { @NonNull public SyncProvider getSyncProvider() { return syncProviderStore.getProvider(); } @Inject  BackupProvidersManager(@NonNull SyncProviderFactory syncProviderFactory,
                                  @NonNull SyncProviderStore syncProviderStore,
                                  @NonNull NetworkManager networkManager); void registerChangeListener(@NonNull BackupProviderChangeListener backupProviderChangeListener); void unregisterChangeListener(@NonNull BackupProviderChangeListener backupProviderChangeListener); synchronized void setAndInitializeSyncProvider(@NonNull SyncProvider syncProvider, @Nullable FragmentActivity fragmentActivity); synchronized void setAndInitializeNetworkProviderType(@NonNull SupportedNetworkType supportedNetworkType); @NonNull SyncProvider getSyncProvider(); @Override synchronized void initialize(@Nullable FragmentActivity activity); @Override synchronized void deinitialize(); @Override synchronized boolean onActivityResult(int requestCode, int resultCode, @Nullable Intent data); @NonNull @Override Single<List<RemoteBackupMetadata>> getRemoteBackups(); @Nullable @Override Identifier getDeviceSyncId(); @NonNull @Override Date getLastDatabaseSyncTime(); @NonNull @Override Single<Boolean> restoreBackup(@NonNull RemoteBackupMetadata remoteBackupMetadata, boolean overwriteExistingData); @NonNull @Override Single<com.google.api.services.drive.model.File> renameBackup(@NonNull RemoteBackupMetadata remoteBackupMetadata, @NonNull String newFileName); @NonNull @Override Single<Boolean> deleteBackup(@NonNull RemoteBackupMetadata remoteBackupMetadata); @Override Single<Boolean> clearCurrentBackupConfiguration(); @NonNull @Override Single<List<File>> downloadAllData(@NonNull RemoteBackupMetadata remoteBackupMetadata, @NonNull File downloadLocation); @NonNull @Override Single<List<File>> debugDownloadAllData(@NonNull RemoteBackupMetadata remoteBackupMetadata, @NonNull File downloadLocation); @NonNull @Override Observable<CriticalSyncError> getCriticalSyncErrorStream(); @Override void markErrorResolved(@NonNull SyncErrorType syncErrorType);  }
@Test public void getSyncProvider() { assertEquals(SyncProvider.None, mBackupProvidersManager.getSyncProvider()); verify(mSyncProviderStore, times(2)).getProvider(); }