|
@@ -1,6 +1,6 @@
|
|
|
package org.dromara.test;
|
|
package org.dromara.test;
|
|
|
|
|
|
|
|
-import org.dromara.common.core.config.RuoYiConfig;
|
|
|
|
|
|
|
+import org.dromara.common.web.config.properties.CaptchaProperties;
|
|
|
import org.junit.jupiter.api.*;
|
|
import org.junit.jupiter.api.*;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.boot.test.context.SpringBootTest;
|
|
import org.springframework.boot.test.context.SpringBootTest;
|
|
@@ -17,19 +17,19 @@ import java.util.concurrent.TimeUnit;
|
|
|
public class DemoUnitTest {
|
|
public class DemoUnitTest {
|
|
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
|
- private RuoYiConfig ruoYiConfig;
|
|
|
|
|
|
|
+ private CaptchaProperties captchaProperties;
|
|
|
|
|
|
|
|
@DisplayName("测试 @SpringBootTest @Test @DisplayName 注解")
|
|
@DisplayName("测试 @SpringBootTest @Test @DisplayName 注解")
|
|
|
@Test
|
|
@Test
|
|
|
public void testTest() {
|
|
public void testTest() {
|
|
|
- System.out.println(ruoYiConfig);
|
|
|
|
|
|
|
+ System.out.println(captchaProperties);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Disabled
|
|
@Disabled
|
|
|
@DisplayName("测试 @Disabled 注解")
|
|
@DisplayName("测试 @Disabled 注解")
|
|
|
@Test
|
|
@Test
|
|
|
public void testDisabled() {
|
|
public void testDisabled() {
|
|
|
- System.out.println(ruoYiConfig);
|
|
|
|
|
|
|
+ System.out.println(captchaProperties);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Timeout(value = 2L, unit = TimeUnit.SECONDS)
|
|
@Timeout(value = 2L, unit = TimeUnit.SECONDS)
|
|
@@ -37,7 +37,7 @@ public class DemoUnitTest {
|
|
|
@Test
|
|
@Test
|
|
|
public void testTimeout() throws InterruptedException {
|
|
public void testTimeout() throws InterruptedException {
|
|
|
Thread.sleep(3000);
|
|
Thread.sleep(3000);
|
|
|
- System.out.println(ruoYiConfig);
|
|
|
|
|
|
|
+ System.out.println(captchaProperties);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|