assertEquals(customer.getSubscriptions().getData().get(0).getPlan().getId(), plan.getId());
}
@Test
public void testUpdateSubscription() throws StripeException {
Plan plan = Plan.create(getUniquePlanParams());
Customer customer = Customer.create(defaultCustomerParams);
Map<String, Object> subscriptionParams = new HashMap<String, Object>();
subscriptionParams.put("plan", plan.getId());
Subscription sub = customer.updateSubscription(subscriptionParams);
assertEquals(sub.getPlan().getId(), plan.getId());
assertEquals(sub.getCustomer(), customer.getId());
}