Atlas › Test

TestCircularReference

Exact test identity: go.temporal.io/server/common/testing/fakedata/TestCircularReference

Package
go.temporal.io/server/common/testing/fakedata
Suite / test hierarchy
TestCircularReference
Test
TestCircularReference
Introduced at
fakedata.go ×1 Frontier kind: Joint frontier
Covered ranges
2
Covered lines
10
Covered files
1

Covered source

Expand a file to inspect source; the > gutter marks covered lines.

go.temporal.io/server/common/testing/fakedata/fakedata.go 10 covered LOC · 2 ranges

Open complete file

9 )
10
11 > func init() { fakedata.go
12 > // We need this option to prevent faker.FakeData from returning an error for any struct that has an interface{} field.
13 > faker.SetIgnoreInterface(true)
14 > // We need this option to prevent faker from taking a long time while generating random data for structs that have
15 > // map or slice fields. This is especially relevant for persistence.ShardInfo, which takes about 1s without this
16 > // option, but only ~100µs with it.
17 > if err := faker.SetRandomMapAndSliceMaxSize(2); err != nil {
18 panic(err)
19 }
24 // var shardInfo persistencespb.ShardInfo
25 // _ = fakedata.FakeStruct(&shardInfo)
26 > func FakeStruct(a any) error { fakedata.go
27 > return faker.FakeData(a)
28 > }