use of com.braintreepayments.api.models.UnionPayCapabilities in project braintree_android by braintree.
the class UnionPayTest method fetchCapabilities_whenCredit_isDebitIsFalse.
@Test(timeout = 10000)
public void fetchCapabilities_whenCredit_isDebitIsFalse() throws InterruptedException {
mBraintreeFragment.addListener(new UnionPayListener() {
@Override
public void onCapabilitiesFetched(UnionPayCapabilities unionPayCapabilities) {
assertTrue(unionPayCapabilities.supportsTwoStepAuthAndCapture());
assertFalse(unionPayCapabilities.isDebit());
assertTrue(unionPayCapabilities.isUnionPay());
mCountDownLatch.countDown();
}
@Override
public void onSmsCodeSent(String enrollmentId, boolean smsCodeRequired) {
fail("Not expecting onSmsCodeSent");
}
});
UnionPay.fetchCapabilities(mBraintreeFragment, UNIONPAY_CREDIT);
mCountDownLatch.await();
}
Aggregations