mirror of
https://gitee.com/dromara/Jpom.git
synced 2024-12-04 12:58:24 +08:00
ssh 快捷安装插件端检查配置文件不在使用 SpringBoot 非 public 工具类
This commit is contained in:
parent
04633ab361
commit
a2fbd6a7d6
@ -1,4 +1,5 @@
|
||||
import cn.hutool.core.io.resource.ResourceUtil;
|
||||
import io.jpom.system.ConfigBean;
|
||||
import org.junit.Test;
|
||||
import org.springframework.boot.env.YamlPropertySourceLoader;
|
||||
import org.springframework.core.env.PropertySource;
|
||||
@ -23,5 +24,8 @@ public class TestYml {
|
||||
List<PropertySource<?>> test = yamlPropertySourceLoader.load("test", new FileUrlResource(path));
|
||||
PropertySource<?> propertySource = test.get(0);
|
||||
System.out.println(propertySource);
|
||||
|
||||
Object user = propertySource.getProperty(ConfigBean.AUTHORIZE_USER_KEY);
|
||||
System.out.println(user);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user