コード例 #1
0
 @Test
 public void shouldRejectUniqueCustomers() {
   cluster.setNumberOfUniqueCustomers(2);
   ValidatorResult result = cTest.validate(cluster, POST);
   assertFalse(resultMessage(result, POST), result.passedValidation());
 }
コード例 #2
0
 @Test
 public void shouldRejectUtiliztation() {
   cluster.setUtilization("1%");
   ValidatorResult result = cTest.validate(cluster, POST);
   assertFalse(resultMessage(result, POST), result.passedValidation());
 }
コード例 #3
0
 @Test
 public void shouldRejectLbConfigs() {
   cluster.setNumberOfLoadBalancingConfigurations(2);
   ValidatorResult result = cTest.validate(cluster, POST);
   assertFalse(resultMessage(result, POST), result.passedValidation());
 }
コード例 #4
0
 @Test
 public void shouldRejectNullDataCenter() {
   cluster.setDataCenter(null);
   ValidatorResult result = cTest.validate(cluster, POST);
   assertFalse(resultMessage(result, POST), result.passedValidation());
 }
コード例 #5
0
 @Test
 public void shouldRejectNullCluster() {
   ValidatorResult result = cTest.validate(null, POST);
   assertFalse(resultMessage(result, POST), result.passedValidation());
 }
コード例 #6
0
 @Test
 public void shouldAcceptValidCluster() {
   ValidatorResult result = cTest.validate(cluster, POST);
   assertTrue(resultMessage(result, POST), result.passedValidation());
 }
コード例 #7
0
 @Test
 public void shouldRejectHostMachines() {
   cluster.setNumberOfHostMachines(2);
   ValidatorResult result = cTest.validate(cluster, PUT);
   assertFalse(resultMessage(result, PUT), result.passedValidation());
 }