@Override
public void processContextConfiguration(ContextConfigurationAttributes configAttributes) {
String className = "io.leopard.javahost.AutoUnitRunnable";
try {
Runnable runnable = (Runnable) Class.forName(className).newInstance();
runnable.run();
}
catch (Exception e) {
// System.err.println("init hosts error:" + e.toString());
// e.printStackTrace();
}
String[] locations = new String[0];
if (locations.length == 0) {
locations = new ApplicationContextLocationImpl().get();
}
// files = ArrayUtil.insertFirst(files, "/leopard-test/annotation-config.xml");
locations = StringUtils.addStringToArray(locations, "/leopard-test/annotation-config.xml");
configAttributes.setLocations(locations);
// System.err.println("processContextConfiguration:" + org.apache.commons.lang.StringUtils.join(configAttributes.getLocations(), ","));
}
TestContextLoader.java 文件源码
java
阅读 22
收藏 0
点赞 0
评论 0
项目:leopard
作者:
评论列表
文章目录