From 0a5367ccfba53fc59f43da4216d0fbbe40d6fba9 Mon Sep 17 00:00:00 2001
From: star <2755454208@qq.com>
Date: Wed, 6 Nov 2024 09:05:11 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=8D=95=E5=85=83=E6=B5=8B?=
=?UTF-8?q?=E8=AF=95?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
ktg-admin/pom.xml | 28 +++++++++++++++++---
ktg-admin/src/test/InventoryTaskTest.java | 32 +++++++++++++++++++++++
ktg-mes/pom.xml | 14 ----------
pom.xml | 15 -----------
4 files changed, 57 insertions(+), 32 deletions(-)
create mode 100644 ktg-admin/src/test/InventoryTaskTest.java
diff --git a/ktg-admin/pom.xml b/ktg-admin/pom.xml
index 1f18087..26b1e76 100644
--- a/ktg-admin/pom.xml
+++ b/ktg-admin/pom.xml
@@ -31,20 +31,42 @@
+
org.springframework.boot
spring-boot-starter-test
- 3.3.0
test
-
junit
junit
- 4.12
test
+
+
+ org.springframework.boot
+ spring-boot-starter-tomcat
+ provided
+
+
+
+
+ org.apache.tomcat.embed
+ tomcat-embed-websocket
+ 8.5.23
+
+
+
+ javax.websocket
+ javax.websocket-api
+ 1.1
+ provided
+
+
+
+
+
diff --git a/ktg-admin/src/test/InventoryTaskTest.java b/ktg-admin/src/test/InventoryTaskTest.java
new file mode 100644
index 0000000..a842a87
--- /dev/null
+++ b/ktg-admin/src/test/InventoryTaskTest.java
@@ -0,0 +1,32 @@
+import com.ktg.RuoYiApplication;
+import com.ktg.mes.qc.domain.InventoryTask;
+import com.ktg.mes.qc.service.InventoryTaskService;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.test.context.junit4.SpringRunner;
+
+@RunWith(SpringRunner.class)
+@SpringBootTest(classes = RuoYiApplication.class,webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
+public class InventoryTaskTest {
+ @Autowired
+ private InventoryTaskService inventoryTaskService;
+ @Test
+ public void saveTest(){
+ //新建任务对象
+ InventoryTask inventoryTaskTest = new InventoryTask();
+ inventoryTaskTest.setWmsInventoryCode("TEST001");
+ inventoryTaskTest.setUomId("TEST001");
+ inventoryTaskTest.setName("测试计划");
+ inventoryTaskTest.setPlanPeriod("月");
+ inventoryTaskTest.setStartTime("2022-01-01");
+ inventoryTaskTest.setFinishTime("2022-12-31");
+ inventoryTaskTest.setSuperiorTime("2022-01-01");
+ inventoryTaskTest.setBelowTime("2022-12-31");
+ inventoryTaskTest.setProductId("TEST001");
+ //新增
+ int i = inventoryTaskService.insertInventoryTask(inventoryTaskTest);
+
+ }
+}
diff --git a/ktg-mes/pom.xml b/ktg-mes/pom.xml
index e861a1b..86a794b 100644
--- a/ktg-mes/pom.xml
+++ b/ktg-mes/pom.xml
@@ -21,20 +21,6 @@
jasperreports
6.18.1
-
-
- org.springframework.boot
- spring-boot-starter-test
- 3.3.0
- test
-
-
-
- junit
- junit
- 4.12
- test
-
net.sf.jasperreports
diff --git a/pom.xml b/pom.xml
index 64b086e..85da62e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -122,21 +122,6 @@
${commons.fileupload.version}
-
-
-
- org.springframework.boot
- spring-boot-starter-test
- 3.3.0
- test
-
-
-
- junit
- junit
- 4.12
- test
-
org.apache.poi