This commit is contained in:
2023-05-05 18:23:40 +08:00
4 changed files with 286 additions and 269 deletions

View File

@@ -1,9 +1,5 @@
server:
port: 8010
#配置数据源
spring:
profiles:
test
datasource:
druid:
db-type: com.alibaba.druid.pool.DruidDataSource

View File

@@ -1,28 +0,0 @@
package org.nl;
import org.junit.After;
import org.junit.Before;
import org.junit.runner.RunWith;
import org.nl.modules.wql.WQLCore;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@RunWith(SpringRunner.class)
public class BaseTest {
@Before
public void init() {
WQLCore.defalutDBName = "eladmin";
WQLCore.ROOT = "org.nl";
try {
WQLCore.init();
} catch (Exception e) {
e.printStackTrace();
}
}
@After
public void after() {
System.out.println("测试结束-----------------");
}
}