コード例 #1
0
  @Before
  public void setup() throws Exception {
    module = new ZuoraModule();
    module.setEndpoint("https://apisandbox.zuora.com/apps/services/a/32.0");
    module.connect(System.getenv("zuoraUsername"), System.getenv("zuoraPassword"));

    for (ZObject z : module.find("select id from Account")) {
      module.delete(ZObjectType.Account, Arrays.asList(z.getId()));
    }
  }
コード例 #2
0
 @Test
 public void getUserInfo() throws Exception {
   User userInfo = module.getUserInfo();
   assertNotNull(userInfo);
   assertFalse(userInfo.getUserId().isEmpty());
   assertFalse(userInfo.getUserEmail().isEmpty());
   assertEquals(System.getenv("zuoraUsername"), userInfo.getUsername());
   assertFalse(userInfo.getTenantId().isEmpty());
   assertFalse(userInfo.getTenantName().isEmpty());
 }