GenerationTest.java 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. package com.gyee.generation;
  2. import com.gyee.generation.service.AnalysisNewService;
  3. import com.gyee.generation.service.PVSystemEfficiencyCalculator;
  4. import com.gyee.generation.service.StationPower.StationPowerService;
  5. import com.gyee.generation.service.initalcache.CacheService;
  6. import com.gyee.generation.service.realtimelibrary.*;
  7. import org.junit.Test;
  8. import org.junit.runner.RunWith;
  9. import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
  10. import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
  11. import org.springframework.boot.test.context.SpringBootTest;
  12. import org.springframework.test.context.junit4.SpringRunner;
  13. import javax.annotation.Resource;
  14. /**
  15. * @ClassName : GenerationTest
  16. * @Author : xieshengjie
  17. * @Date: 2022/3/8 9:17
  18. * @Description :
  19. */
  20. @SpringBootTest
  21. @RunWith(SpringRunner.class)
  22. @EnableAutoConfiguration(exclude={DataSourceAutoConfiguration.class})
  23. public class GenerationTest {
  24. @Resource
  25. private CacheService cacheService;
  26. @Resource
  27. private ElectricityMeteringService electricityMeteringService;
  28. @Resource
  29. private RealtimeService realtimeService; //实时补风,实时功率
  30. @Resource
  31. private CycleCalculationService cycleCalculationService; //日月年
  32. @Resource
  33. private StatusService statusService;
  34. @Resource
  35. private RegionCalreService regionCalreService;
  36. @Resource
  37. private RegionCalService regionCalService;
  38. @Resource
  39. private AccessStatusService accessStatusService;
  40. @Resource
  41. private CalculationService calculationService;
  42. @Resource
  43. private SafetyDayService safetyDayService;
  44. @Resource
  45. private StationPowerService stationPowerService;
  46. @Resource
  47. private PVSystemEfficiencyCalculator calculator;
  48. @Resource
  49. private AnalysisNewService analysisNewService;
  50. @Test
  51. public void test1() throws Exception {
  52. cacheService.initRedisCache();
  53. // electricityMeteringService.saveGenerationDatas();
  54. }
  55. @Test
  56. public void test2() throws Exception {
  57. // electricityMeteringService.saveGenerationDatas();
  58. // realtimeService.savaRealtimeTarget();
  59. // cycleCalculationService.saveCyle();
  60. // statusService.powerRationing();
  61. statusService.startStatusReal();
  62. // statusService.calculateStatusNumber();
  63. // regionCalService.companyCal();
  64. // regionCalService.RegionCal();
  65. //
  66. // regionCalreService.companyCal();
  67. // regionCalreService.RegionCal();
  68. }
  69. @Test
  70. public void test3() throws Exception {
  71. // //场站接入状态,总预测功率
  72. // accessStatusService.accessStatus();
  73. // //全场状态
  74. // accessStatusService.fullFieldState();
  75. // statusService.powerRationing();
  76. // statusService.statusReal();
  77. // statusService.calculateStatusNumber();
  78. // realtimeService.savaRealtimeTarget();
  79. // cycleCalculationService.saveCyle();
  80. // electricityMeteringService.saveGenerationDatas();
  81. // calculationService.calWp();
  82. // regionCalService.companyCal();
  83. // regionCalService.RegionCal();
  84. // regionCalreService.companyCal();
  85. // regionCalreService.RegionCal();
  86. // safetyDayService.saveSafetyday();
  87. // stationPowerService.predictedPower();
  88. calculator.planvalue();
  89. analysisNewService.companys();
  90. analysisNewService.saveWindProject();
  91. }
  92. }