Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1035)

Unified Diff: common/logdog/fetcher/fetcher_test.go

Issue 1672833003: LogDog: Add log rendering view. Base URL: https://github.com/luci/luci-go@master
Patch Set: Clean up, add tests, little reorg. Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « common/logdog/fetcher/fetcher.go ('k') | server/logdog/storage/archive/storage.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: common/logdog/fetcher/fetcher_test.go
diff --git a/common/logdog/fetcher/fetcher_test.go b/common/logdog/fetcher/fetcher_test.go
index d5aa0a198a4ae6982dddd5225cbc1cd544c63574..03e132f672e273db40c56c425a8f30257b080d75 100644
--- a/common/logdog/fetcher/fetcher_test.go
+++ b/common/logdog/fetcher/fetcher_test.go
@@ -29,7 +29,7 @@ type testSource struct {
panic bool
terminal types.MessageIndex
- maxCount int
+ maxCount int64
maxBytes int64
history []int
@@ -58,7 +58,7 @@ func (ts *testSource) LogEntries(c context.Context, req *LogRequest) ([]*logpb.L
maxCount = ts.maxCount
}
if maxCount <= 0 {
- maxCount = len(ts.logs)
+ maxCount = int64(len(ts.logs))
}
maxBytes := req.Bytes
@@ -70,7 +70,7 @@ func (ts *testSource) LogEntries(c context.Context, req *LogRequest) ([]*logpb.L
bytes := int64(0)
index := req.Index
for {
- if len(logs) >= maxCount {
+ if int64(len(logs)) >= maxCount {
break
}
« no previous file with comments | « common/logdog/fetcher/fetcher.go ('k') | server/logdog/storage/archive/storage.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698