From a32fb40006078a76ca216152dc1e4582cfb04b50 Mon Sep 17 00:00:00 2001 From: Paolo Teti Date: Tue, 12 Mar 2024 11:49:46 +0100 Subject: [PATCH] [IMPROVED] Fixed typos in comments (#1581) Co-authored-by: Paolo TETI --- bench/bench.go | 4 ++-- bench/benchlib_test.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bench/bench.go b/bench/bench.go index cb724737f..4ea4b3056 100644 --- a/bench/bench.go +++ b/bench/bench.go @@ -36,7 +36,7 @@ type Sample struct { End time.Time } -// SampleGroup for a number of samples, the group is a Sample itself agregating the values the Samples +// SampleGroup for a number of samples, the group is a Sample itself aggregating the values the Samples type SampleGroup struct { Sample Samples []*Sample @@ -156,7 +156,7 @@ func (s *Sample) Throughput() float64 { return float64(s.MsgBytes) / s.Duration().Seconds() } -// Rate of meessages in the job per second +// Rate of messages in the job per second func (s *Sample) Rate() int64 { return int64(float64(s.JobMsgCnt) / s.Duration().Seconds()) } diff --git a/bench/benchlib_test.go b/bench/benchlib_test.go index d3b515c0f..020bae45c 100644 --- a/bench/benchlib_test.go +++ b/bench/benchlib_test.go @@ -116,7 +116,7 @@ func TestGroupThoughput(t *testing.T) { sg.AddSample(millionMessagesSecondSample(2)) sg.AddSample(millionMessagesSecondSample(3)) if sg.Throughput() != 2*Million*MsgSize { - t.Fatalf("Expected througput at %d million bytes/sec", 2*MsgSize) + t.Fatalf("Expected throughput at %d million bytes/sec", 2*MsgSize) } }