Search in sources :

Example 1 with EncryptedSharedPreferences

use of androidx.security.crypto.EncryptedSharedPreferences in project braintree_android by braintree.

the class BraintreeSharedPreferencesTest method getSharedPreferences_returnsEncryptedSharedPreferences.

@Test
public void getSharedPreferences_returnsEncryptedSharedPreferences() {
    BraintreeSharedPreferences sut = BraintreeSharedPreferences.getInstance();
    SharedPreferences sharedPreferences = getSharedPreferences(ApplicationProvider.getApplicationContext());
    assertTrue(sharedPreferences instanceof EncryptedSharedPreferences);
}
Also used : EncryptedSharedPreferences(androidx.security.crypto.EncryptedSharedPreferences) BraintreeSharedPreferences.getSharedPreferences(com.braintreepayments.api.BraintreeSharedPreferences.getSharedPreferences) SharedPreferences(android.content.SharedPreferences) EncryptedSharedPreferences(androidx.security.crypto.EncryptedSharedPreferences) Test(org.junit.Test)

Aggregations

SharedPreferences (android.content.SharedPreferences)1 EncryptedSharedPreferences (androidx.security.crypto.EncryptedSharedPreferences)1 BraintreeSharedPreferences.getSharedPreferences (com.braintreepayments.api.BraintreeSharedPreferences.getSharedPreferences)1 Test (org.junit.Test)1