Package org.jclouds.compute.domain

Examples of org.jclouds.compute.domain.TemplateBuilder.osVersionMatches()


      if (osFamily != null) {
         builder.osFamily(OsFamily.fromValue(osFamily));
      }

      if (osVersion != null) {
         builder.osVersionMatches(osVersion);
      }

      TemplateOptions options = service.templateOptions();
      List<Statement> statements = Lists.newLinkedList();
View Full Code Here


   @Test(dataProvider = "osSupported")
   public void testTemplateBuilderCanFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      Template template = builder.build();
      if (!matrix.version.equals(""))
         assertEquals(template.getImage().getOperatingSystem().getVersion(), matrix.version);
      assertEquals(template.getImage().getOperatingSystem().is64Bit(), matrix.is64Bit);
      assertEquals(template.getImage().getOperatingSystem().getFamily(), matrix.family);
View Full Code Here

   @Test(dataProvider = "osNotSupported", expectedExceptions = NoSuchElementException.class)
   public void testTemplateBuilderCannotFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      builder.build();
   }

   @Test
   public void testTemplateBuilderCanUseImageId() throws Exception {
View Full Code Here

      if (osFamily != null) {
         builder.osFamily(OsFamily.fromValue(osFamily));
      }

      if (osVersion != null) {
         builder.osVersionMatches(osVersion);
      }

      TemplateOptions options = service.templateOptions();
      List<Statement> statements = Lists.newLinkedList();
View Full Code Here

   @Test(dataProvider = "osSupported")
   public void testTemplateBuilderCanFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      Template template = builder.build();
      if (!matrix.version.equals(""))
         assertEquals(template.getImage().getOperatingSystem().getVersion(), matrix.version);
      assertEquals(template.getImage().getOperatingSystem().is64Bit(), matrix.is64Bit);
      assertEquals(template.getImage().getOperatingSystem().getFamily(), matrix.family);
View Full Code Here

   @Test(dataProvider = "osNotSupported", expectedExceptions = NoSuchElementException.class)
   public void testTemplateBuilderCannotFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      builder.build();
   }

   @Test
   public void testTemplateBuilderCanUseImageId() throws Exception {
View Full Code Here

   @Test(dataProvider = "osSupported")
   public void testTemplateBuilderCanFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      Template template = builder.build();
      if (!matrix.version.equals(""))
         assertEquals(template.getImage().getOperatingSystem().getVersion(), matrix.version);
      assertEquals(template.getImage().getOperatingSystem().is64Bit(), matrix.is64Bit);
      assertEquals(template.getImage().getOperatingSystem().getFamily(), matrix.family);
View Full Code Here

   @Test(dataProvider = "osNotSupported", expectedExceptions = NoSuchElementException.class)
   public void testTemplateBuilderCannotFind(OsFamilyVersion64Bit matrix) throws InterruptedException {
      TemplateBuilder builder = view.getComputeService().templateBuilder().osFamily(matrix.family)
            .os64Bit(matrix.is64Bit);
      if (!matrix.version.equals(""))
         builder.osVersionMatches("^" + matrix.version + "$");
      builder.build();
   }

   @Test
   public void testTemplateBuilderCanUseImageId() throws Exception {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.