From 538ba7a3bbc682f4537f1dd34f93feb2cf56b08e Mon Sep 17 00:00:00 2001
From: feiyu02 <risaku@163.com>
Date: 星期二, 14 十月 2025 17:32:04 +0800
Subject: [PATCH] 2025.10.14 1. 新增数据统计颗粒度选项,可选秒级数据、分钟数据进行数据统计 2. 典型隐患区域统计新增按照污染溯源区域进行分类统计的功能
---
src/test/kotlin/com/flightfeather/uav/lightshare/service/impl/MissionServiceImplTest.kt | 23 +++++++++++++++++++----
1 files changed, 19 insertions(+), 4 deletions(-)
diff --git a/src/test/kotlin/com/flightfeather/uav/lightshare/service/impl/MissionServiceImplTest.kt b/src/test/kotlin/com/flightfeather/uav/lightshare/service/impl/MissionServiceImplTest.kt
index a5b4ef3..3d3dba5 100644
--- a/src/test/kotlin/com/flightfeather/uav/lightshare/service/impl/MissionServiceImplTest.kt
+++ b/src/test/kotlin/com/flightfeather/uav/lightshare/service/impl/MissionServiceImplTest.kt
@@ -1,15 +1,16 @@
package com.flightfeather.uav.lightshare.service.impl
+import com.flightfeather.uav.biz.FactorFilter
import com.flightfeather.uav.biz.report.MissionReport
+import com.flightfeather.uav.domain.entity.Mission
+import com.flightfeather.uav.domain.mapper.MissionMapper
import com.flightfeather.uav.lightshare.service.MissionService
import org.junit.Test
-
-import org.junit.Assert.*
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
-import javax.servlet.http.HttpServletResponse
+import tk.mybatis.mapper.entity.Example
@RunWith(SpringRunner::class)
@SpringBootTest
@@ -19,10 +20,24 @@
lateinit var missionService: MissionService
@Autowired
+ lateinit var missionMapper: MissionMapper
+
+ @Autowired
lateinit var missionReport: MissionReport
@Test
fun getReport() {
- missionReport.execute("SH-CN-20240514")
+ missionReport.execute("SH-CN-20240723-01", FactorFilter.default())
+ missionReport.execute("SH-CN-20240723-02", FactorFilter.default())
+ }
+
+ @Test
+ fun calMissionInfo() {
+ missionMapper.selectByExample(Example(Mission::class.java).apply {
+ createCriteria().andGreaterThanOrEqualTo("startTime", "2025-08-08 08:30:00")
+ }).forEach {mission ->
+ mission?.let { missionService.calMissionInfo(it.missionCode) }
+ Thread.sleep(1000)
+ }
}
}
\ No newline at end of file
--
Gitblit v1.9.3