### Question:
StrutsConfigUtils extends ModulePluginUtils { public static Resource[] getStrutsConfigResources() { List<Resource> resourcesList = new ArrayList<Resource>(16); Enumeration<ModulePluginDriverInfo> dirverInfos = getDriverInfos(); SystemLogUtils.rootPrintln("Struts Config 配置文件Find Begin！"); while (dirverInfos.hasMoreElements()) { ModulePluginDriverInfo driverInfo = dirverInfos.nextElement(); if (!(driverInfo.getDriver() instanceof IStrutsSupport)) continue; SystemLogUtils.secondPrintln(driverInfo.getDriver() + "Struts Config 配置文件Find！"); List<Resource> list = getStrutsConfigResources(driverInfo); resourcesList.addAll(list); SystemLogUtils.thirdPrintln(driverInfo.getDriver() + "找到(" + list.size() + ")个配置文件！"); } SystemLogUtils.rootPrintln("Struts Config 配置文件 Find End！"); return resourcesList.toArray(new Resource[resourcesList.size()]); }  static Resource[] getStrutsConfigResources(); static List<Resource> getStrutsConfigResources(ModulePluginDriverInfo driverInfo);  }### Answer:
@Test public void testGetStrutsConfigResources() { Resource[] resources = StrutsConfigUtils.getStrutsConfigResources(); Assert.assertTrue("加载Struts 配置文件错误！", resources.length == 1); }
@Test public void testGetStrutsConfigResourcesModulePluginDriverInfo() { Enumeration<IStrutsSupport> strutsSupports = StrutsConfigUtils.getDrivers(IStrutsSupport.class); int i = 0; while (strutsSupports.hasMoreElements()) { ModulePluginDriver driver = (ModulePluginDriver) strutsSupports.nextElement(); ModulePluginDriverInfo driverInfo = StrutsConfigUtils.getDriverInfo(driver.getClass().getName()); List<Resource> list = StrutsConfigUtils.getStrutsConfigResources(driverInfo); Assert.assertTrue("加载Struts 配置文件错误！", list.size() == 1); i++; } if (i == 0) { fail("没有找到Struts 配置文件驱动！"); } }