Ejemplo n.º 1
0
 private VDS createServer(Guid serverId, String hostname) {
   VDS vds = new VDS();
   vds.setId(serverId);
   vds.setHostName(hostname);
   vds.setStatus(VDSStatus.Up);
   return vds;
 }
Ejemplo n.º 2
0
 private List<VDS> mockVdsInDb(VDSStatus status) {
   List<VDS> vdsList = new ArrayList<>();
   VDS vds = new VDS();
   vds.setStatus(status);
   vdsList.add(vds);
   return vdsList;
 }
Ejemplo n.º 3
0
 private void vdsExist() {
   VDS vds = new VDS();
   vds.setStatus(VDSStatus.Up);
   List<VDS> vdsList = new ArrayList<>();
   vdsList.add(vds);
   when(vdsDao.getAllForCluster(any(Guid.class))).thenReturn(vdsList);
 }
 private VDS getVds(VDSStatus status) {
   VDS vds = new VDS();
   vds.setId(Guid.newGuid());
   vds.setVdsName("gfs1");
   vds.setVdsGroupId(CLUSTER_ID);
   vds.setStatus(status);
   return vds;
 }
Ejemplo n.º 5
0
 private void clusterHasVds() {
   VDS vds = new VDS();
   vds.setStatus(VDSStatus.Up);
   vds.setSupportedClusterLevels(VERSION_1_1.toString());
   List<VDS> vdsList = new ArrayList<>();
   vdsList.add(vds);
   when(vdsDao.getAllForCluster(any(Guid.class))).thenReturn(vdsList);
 }
Ejemplo n.º 6
0
 private void vdsExistWithHigherVersion() {
   VDS vds = new VDS();
   vds.setStatus(VDSStatus.Up);
   vds.setClusterCompatibilityVersion(VERSION_1_2);
   List<VDS> vdsList = new ArrayList<>();
   vdsList.add(vds);
   when(vdsDao.getAllForCluster(any(Guid.class))).thenReturn(vdsList);
 }
 private VDS getVds(VDSStatus status) {
   VDS vds = new VDS();
   vds.setId(Guid.newGuid());
   vds.setVdsName("gfs1");
   vds.setClusterId(clusterId);
   vds.setStatus(status);
   return vds;
 }