1 16 17 package org.springframework.jmx.export.naming; 18 19 import java.util.Properties ; 20 21 25 public class PropertiesNamingStrategyTests extends AbstractNamingStrategyTests { 26 27 private static final String OBJECT_NAME = "bean:name=namingTest"; 28 29 protected ObjectNamingStrategy getStrategy() throws Exception { 30 KeyNamingStrategy strat = new KeyNamingStrategy(); 31 Properties mappings = new Properties (); 32 mappings.setProperty("namingTest", "bean:name=namingTest"); 33 strat.setMappings(mappings); 34 strat.afterPropertiesSet(); 35 return strat; 36 } 37 38 protected Object getManagedResource() { 39 return new Object (); 40 } 41 42 protected String getKey() { 43 return "namingTest"; 44 } 45 46 protected String getCorrectObjectName() { 47 return OBJECT_NAME; 48 } 49 50 } 51 | Popular Tags |