@Test public void testResourceEnvRefType() throws Exception { TestDescriptorImpl provider = new TestDescriptorImpl("test"); ResourceEnvRefType<TestDescriptorImpl> type = new ResourceEnvRefTypeImpl<TestDescriptorImpl>( provider, "resource-env-refType", provider.getRootNode()); type.setResourceEnvRefType("test"); assertEquals(type.getResourceEnvRefType(), "test"); type.removeResourceEnvRefType(); assertNull(type.getResourceEnvRefType()); }
@Test public void testDescription() throws Exception { TestDescriptorImpl provider = new TestDescriptorImpl("test"); ResourceEnvRefType<TestDescriptorImpl> type = new ResourceEnvRefTypeImpl<TestDescriptorImpl>( provider, "resource-env-refType", provider.getRootNode()); type.setDescription("value1"); type.setDescription("value2"); type.setDescriptionList("value3", "value4"); assertTrue(type.getDescriptionList().size() == 4); assertEquals(type.getDescriptionList().get(0), "value1"); assertEquals(type.getDescriptionList().get(1), "value2"); assertEquals(type.getDescriptionList().get(2), "value3"); assertEquals(type.getDescriptionList().get(3), "value4"); type.removeAllDescription(); assertTrue(type.getDescriptionList().size() == 0); }