Browse Source

REPORT-43744 【10.0.13】插件与jar包不匹配问题优化

feature/big-screen
lucian 4 years ago
parent
commit
8eec120925
  1. 2
      designer-base/src/main/java/com/fr/design/extra/PluginOperateUtils.java
  2. 2
      designer-base/src/test/java/com/fr/design/extra/PluginOperateUtilsTest.java

2
designer-base/src/main/java/com/fr/design/extra/PluginOperateUtils.java

@ -231,7 +231,7 @@ public class PluginOperateUtils {
else if (pluginMarker instanceof PluginMarkerAdapter) {
return ((PluginMarkerAdapter) pluginMarker).getPluginName();
}
return pluginMarker == null ? null : pluginMarker.getPluginID();
return pluginMarker == null ? StringUtils.EMPTY : pluginMarker.getPluginID();
}
public static String getSwitchedInfo(PluginTaskResult result) {

2
designer-base/src/test/java/com/fr/design/extra/PluginOperateUtilsTest.java

@ -92,7 +92,7 @@ public class PluginOperateUtilsTest {
EasyMock.replay(pluginContext);
Assert.assertNull(Reflect.on(PluginOperateUtils.class).call("getPluginName", null, null).get());
Assert.assertEquals(Reflect.on(PluginOperateUtils.class).call("getPluginName", null, null).get(), "");
Assert.assertEquals(Reflect.on(PluginOperateUtils.class).call("getPluginName", pluginContext, pluginMarker1).get(), "pluginContext");
Assert.assertEquals(Reflect.on(PluginOperateUtils.class).call("getPluginName", null, pluginMarker1).get(), "id-1");
Assert.assertEquals(Reflect.on(PluginOperateUtils.class).call("getPluginName", null, pluginMarker2).get(), "name-2");

Loading…
Cancel
Save