Skip to content

Commit

Permalink
修复单元测试更新版本号
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinhuangwl committed Mar 26, 2024
1 parent ed2ff83 commit 3846910
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ public synchronized void update(Tick tick) {
}
if(Objects.isNull(cutoffTime)) {
cutoffDT = LocalDateTime.of(tick.actionDay(), tick.actionTime().withSecond(0).withNano(0)).plusMinutes(1);
cutoffTime = CommonUtils.localDateTimeToMills(cutoffDT);
open = tick.lastPrice();
high = tick.lastPrice();
low = tick.lastPrice();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

import lombok.extern.slf4j.Slf4j;

@Slf4j
class MinuteBarGeneratorTest {

MinuteBarGenerator barGen;
Expand All @@ -41,15 +44,17 @@ void testSHFEDuringMarketTime() {
for(int i=0; i<=120; i++) {
time = time.plusNanos(500*1000000);
long timestamp = CommonUtils.localDateTimeToMills(LocalDateTime.of(date, time));
barGen.update(Tick.builder()
Tick t = Tick.builder()
.contract(c)
.tradingDay(date)
.actionDay(date)
.actionTime(time)
.actionTimestamp(timestamp)
.channelType(ChannelType.CTP)
.type(TickType.MARKET_TICK)
.build());
.build();
log.info("{} {} {}", date, time, timestamp);
barGen.update(t);
}
assertThat(results).isNotEmpty();
}
Expand Down
2 changes: 1 addition & 1 deletion northstar-monitor/electron-egg/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "northstar-desktop",
"version": "7.1.0",
"version": "7.1.0-SNAPSHOT",
"description": "A fast, desktop software development framework",
"main": "main.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion northstar-monitor/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion northstar-monitor/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "northstar-monitor",
"version": "7.1.0",
"version": "7.1.0-SNAPSHOT",
"private": true,
"main": "electron/main.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<url>https://gitee.com/dromara/northstar</url>

<properties>
<northstar-version>7.1.0</northstar-version>
<northstar-version>7.1.0-SNAPSHOT</northstar-version>
<java.version>21</java.version>
<argLine>-Dfile.encoding=UTF-8</argLine>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down

0 comments on commit 3846910

Please sign in to comment.