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
| package com.everyday.word;
|
| import org.junit.jupiter.api.Test;
| import org.springframework.boot.test.context.SpringBootTest;
| import org.yeshi.utils.tencentcloud.COSManager;
|
| import javax.annotation.Resource;
| import java.io.File;
|
| /**
| * @author hxh
| * @title: RedisTest
| * @description: COS测试
| * @date 2025/2/13 10:11
| */
| @SpringBootTest
| public class CosTest {
|
| @Resource
| private COSManager cosManager;
|
| @Test
| public void test() {
| cosManager.uploadFile(new File("D:\\项目\\单词\\源代码\\server\\src\\main\\resources\\static\\index.html"),"user/test.html");
| }
|
|
| }
|
|