Package org.jclouds.compute.options

Examples of org.jclouds.compute.options.TemplateOptions


      assertEquals(options.as(CloudStackTemplateOptions.class).getSecurityGroupIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testSecurityGroupIds() {
      TemplateOptions options = new CloudStackTemplateOptions().securityGroupIds(ImmutableSet.of("3"));
      assertEquals(options.as(CloudStackTemplateOptions.class).getSecurityGroupIds(), ImmutableSet.of("3"));
   }


      assertEquals(options.as(CloudStackTemplateOptions.class).getSecurityGroupIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testSecurityGroupIdsStatic() {
      TemplateOptions options = securityGroupIds(ImmutableSet.of("3"));
      assertEquals(options.as(CloudStackTemplateOptions.class).getSecurityGroupIds(), ImmutableSet.of("3"));
   }

      assertEquals(options.as(CloudStackTemplateOptions.class).getSecurityGroupIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testGenerateSecurityGroupDefaultsFalse() {
      TemplateOptions options = new CloudStackTemplateOptions();
      assertFalse(options.as(CloudStackTemplateOptions.class)
         .shouldGenerateSecurityGroup());
   }

         .shouldGenerateSecurityGroup());
   }

   @Test
   public void testGenerateSecurityGroup() {
      TemplateOptions options = new CloudStackTemplateOptions().generateSecurityGroup(true);
      assertTrue(options.as(CloudStackTemplateOptions.class)
         .shouldGenerateSecurityGroup());
   }

         .shouldGenerateSecurityGroup());
   }

   @Test
   public void testGenerateSecurityGroupStatic() {
      TemplateOptions options = generateSecurityGroup(true);
      assertTrue(options.as(CloudStackTemplateOptions.class)
         .shouldGenerateSecurityGroup());
   }

         .shouldGenerateSecurityGroup());
   }

   @Test
   public void testDefaultNetworkIds() {
      TemplateOptions options = new CloudStackTemplateOptions();
      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of());
   }

      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of());
   }

   @Test
   public void testNetworkId() {
      TemplateOptions options = new CloudStackTemplateOptions().networkId("3");
      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testNetworkIdStatic() {
      TemplateOptions options = networkId("3");
      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testNetworkIds() {
      TemplateOptions options = new CloudStackTemplateOptions().networkIds(ImmutableSet.of("3"));
      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

   @Test
   public void testNetworkIdsStatic() {
      TemplateOptions options = networkIds(ImmutableSet.of("3"));
      assertEquals(options.as(CloudStackTemplateOptions.class).getNetworkIds(), ImmutableSet.of("3"));
   }

TOP

Related Classes of org.jclouds.compute.options.TemplateOptions

Copyright © 2018 www.massapicom. 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.