From e0efc237a4c10693b370d70cf4f35eaee9018298 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Sat, 11 May 2019 12:13:34 -0700 Subject: [PATCH] Make a sample set of protobufs Signed-off-by: Jeff Carr --- sampleData.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/sampleData.go b/sampleData.go index 3a2ffe0..19281ac 100644 --- a/sampleData.go +++ b/sampleData.go @@ -25,3 +25,21 @@ func CreateSampleEvent() *Event { return e } + +func CreateSampleEvents(total int) []Event { + // TODO: flush this out to do all the fields + log.Println("CreateSampleEvent() is generating %d protobuf Events", total) + + var all []Event + + for i := 0; i < total; i++ { + e := CreateSampleEvent() + + e.Id += 1000 + int32(i) + e.Name = "jcarrEvent2" + + all = append(all, *e) + } + + return all +}