gao
2020-06-05 01aa2cc5c8fafd89ff763bfb0016c4983ff79648
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
package com.xcong.excoin;
 
import com.xcong.excoin.common.enumerates.CoinTypeEnum;
import com.xcong.excoin.common.enumerates.SymbolEnum;
import com.xcong.excoin.configurations.properties.AliOssProperties;
import com.xcong.excoin.modules.test.dao.TestUserDao;
import com.xcong.excoin.modules.test.entity.TestUserEntity;
import com.xcong.excoin.modules.test.service.TestUserService;
import lombok.extern.slf4j.Slf4j;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
 
import javax.annotation.Resource;
import java.util.Date;
 
@Slf4j
@SpringBootTest
class KssframeworkApplicationTests {
 
    @Resource
    private TestUserDao testUserDao;
 
    @Test
    public void testUserInsert() {
        for(int i = 0; i < 20; i++) {
            TestUserEntity testUser = new TestUserEntity();
            testUser.setCreateBy("123");
            testUser.setCreateTime(new Date());
            testUser.setUpdateBy("123");
            testUser.setUpdateTime(new Date());
            testUser.setAccount("12345" + i);
            testUser.setName("hehe" + i);
            testUser.setPassword("33333");
            testUserDao.insert(testUser);
        }
 
    }
 
    @Resource
    TestUserService testUserService;
 
    @Test
    public void mybatisInterceptorTest() {
        TestUserEntity testUser = new TestUserEntity();
        testUser.setId(3L);
        testUser.setAccount("123333345");
        testUser.setName("hehe111");
        testUser.setPassword("33333");
 
        testUserDao.updateById(testUser);
 
    }
 
    @Test
    public void enumTest() {
        System.out.println(SymbolEnum.BCH.getValue());
    }
 
    @Resource
    AliOssProperties aliOssProperties;
 
    @Test
    public void aliyunOssTest() {
        log.info("{}", aliOssProperties.getEndPoint());
    }
 
 
}