mirror of
https://codeup.aliyun.com/64f7d6b8ce01efaafef1e678/coal/coal.git
synced 2026-01-25 15:55:18 +08:00
完善
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
package cn.lihongjie.coal.entity;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.time.LocalTime;
|
||||
import java.util.Arrays;
|
||||
|
||||
class CoalWashingDailyAnalysisEntityTest {
|
||||
|
||||
|
||||
@Test
|
||||
void test1() {
|
||||
|
||||
CoalWashingDailyAnalysisEntity analysis = new CoalWashingDailyAnalysisEntity();
|
||||
|
||||
CoalWashingDailyAnalysisItemVo vo1 = new CoalWashingDailyAnalysisItemVo();
|
||||
vo1.setC0p0(100.0);
|
||||
vo1.setC0p1(10.0);
|
||||
vo1.setC0p2(12.0);
|
||||
vo1.setTime(LocalTime.of(1, 0));
|
||||
vo1.setTotalNumber(10.0);
|
||||
|
||||
|
||||
CoalWashingDailyAnalysisItemVo vo2 = new CoalWashingDailyAnalysisItemVo();
|
||||
vo2.setC0p0(100.0);
|
||||
vo2.setC0p1(10.0);
|
||||
vo2.setC0p2(12.0);
|
||||
vo2.setTime(LocalTime.of(2, 0));
|
||||
vo2.setTotalNumber(12.0);
|
||||
|
||||
analysis.setInputItems(Arrays.asList(vo1, vo2));
|
||||
|
||||
analysis.rollingAvg();
|
||||
|
||||
System.out.println(analysis);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user