mirror of
https://gitee.com/rulego/streamsql.git
synced 2026-04-10 06:19:52 +00:00
fix(测试): 修正TestStreamData中的结果验证
This commit is contained in:
+2
-1
@@ -30,6 +30,7 @@ func TestStreamData(t *testing.T) {
|
||||
defer cancel()
|
||||
// 添加测试数据
|
||||
go func() {
|
||||
defer wg.Done()
|
||||
ticker := time.NewTicker(1 * time.Second)
|
||||
defer ticker.Stop()
|
||||
for {
|
||||
@@ -81,7 +82,7 @@ func TestStreamData(t *testing.T) {
|
||||
wg.Wait()
|
||||
|
||||
// 验证是否收到了结果
|
||||
assert.Greater(t, resultCount, 5, "应该至少收到一个结果")
|
||||
assert.Equal(t, resultCount, 5, "应该至少收到一个结果")
|
||||
}
|
||||
func TestStreamsql(t *testing.T) {
|
||||
streamsql := New()
|
||||
|
||||
Reference in New Issue
Block a user