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 cn.flightfeather.supervision.lightshare.web
 
import cn.flightfeather.supervision.common.utils.Constant
import cn.flightfeather.supervision.lightshare.service.DataProdMiddleService
import cn.flightfeather.supervision.lightshare.vo.dataprod.QueryOpt
import cn.flightfeather.supervision.lightshare.vo.dataprod.middle.DPTypicalProblemScene
import org.junit.Test
import org.junit.jupiter.api.AfterEach
import org.junit.jupiter.api.BeforeEach
import org.junit.jupiter.api.extension.ExtendWith
import org.junit.runner.RunWith
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.test.context.SpringBootTest
import org.springframework.test.context.junit.jupiter.SpringExtension
import org.springframework.test.context.junit4.SpringRunner
import java.time.LocalDateTime
import kotlin.test.assertEquals
 
@RunWith(SpringRunner::class)
@ExtendWith(SpringExtension::class)
@SpringBootTest
class DataProdMiddleControllerTest {
 
    @Autowired
    lateinit var dataProdMiddleService: DataProdMiddleService
 
    private val queryOpt = QueryOpt().apply{
        topTaskId = "cFnO09ldeQeP1XEg"
        provinceCode = "31"
        cityCode = "3100"
        districtCode = "310104"
        startTime = LocalDateTime.of(2025, 7, 1, 0, 0, 0)
        endTime = LocalDateTime.of(2025, 7, 31, 23, 59, 59)
        sceneTypeId = Constant.SceneType.TYPE1.value
        needCache = true
    }
 
    @BeforeEach
    fun setUp() {
 
    }
 
    @AfterEach
    fun tearDown() {
    }
 
    @Test
    fun getInspectionSummary() {
    }
 
    @Test
    fun getProblemTypeSummary() {
    }
 
    @Test
    fun getProblemCountByArea() {
    }
 
    @Test
    fun getEvaluationByArea() {
    }
 
    @Test
    fun getTypicalProblems() {
        val res = dataProdMiddleService.getTypicalProblems(queryOpt)
        println(res)
    }
}