@@ -53,7 +53,7 @@ func TestFileRetrieval(t *testing.T) {
5353 nodeCount = []int {16 }
5454
5555 if * longrunning {
56- nodeCount = append (nodeCount , 32 , 64 , 128 )
56+ nodeCount = append (nodeCount , 32 , 64 )
5757 } else if testutil .RaceEnabled {
5858 nodeCount = []int {4 }
5959 }
@@ -86,7 +86,7 @@ func TestRetrieval(t *testing.T) {
8686 chnkCnt := []int {32 }
8787
8888 if * longrunning {
89- nodeCnt = []int {16 , 32 , 128 }
89+ nodeCnt = []int {16 , 32 , 64 }
9090 chnkCnt = []int {4 , 32 , 256 }
9191 } else if testutil .RaceEnabled {
9292 nodeCnt = []int {4 }
@@ -113,10 +113,15 @@ var retrievalSimServiceMap = map[string]simulation.ServiceFunc{
113113 return nil , nil , err
114114 }
115115
116+ syncUpdateDelay := 1 * time .Second
117+ if * longrunning {
118+ syncUpdateDelay = 3 * time .Second
119+ }
120+
116121 r := NewRegistry (addr .ID (), delivery , netStore , state .NewInmemoryStore (), & RegistryOptions {
117122 Retrieval : RetrievalEnabled ,
118123 Syncing : SyncingAutoSubscribe ,
119- SyncUpdateDelay : 3 * time . Second ,
124+ SyncUpdateDelay : syncUpdateDelay ,
120125 }, nil )
121126
122127 cleanup = func () {
@@ -140,7 +145,7 @@ func runFileRetrievalTest(nodeCount int) error {
140145 sim := simulation .New (retrievalSimServiceMap )
141146 defer sim .Close ()
142147
143- log .Info ("Initializing test config" )
148+ log .Info ("Initializing test config" , "node count" , nodeCount )
144149
145150 conf := & synctestConfig {}
146151 //map of discover ID to indexes of chunks expected at that ID
@@ -158,6 +163,8 @@ func runFileRetrievalTest(nodeCount int) error {
158163 ctx , cancelSimRun := context .WithTimeout (context .Background (), 3 * time .Minute )
159164 defer cancelSimRun ()
160165
166+ log .Info ("Starting simulation" )
167+
161168 result := sim .Run (ctx , func (ctx context.Context , sim * simulation.Simulation ) error {
162169 nodeIDs := sim .UpNodeIDs ()
163170 for _ , n := range nodeIDs {
@@ -185,6 +192,8 @@ func runFileRetrievalTest(nodeCount int) error {
185192 return err
186193 }
187194
195+ log .Info ("network healthy, start file checks" )
196+
188197 // File retrieval check is repeated until all uploaded files are retrieved from all nodes
189198 // or until the timeout is reached.
190199 REPEAT:
@@ -212,6 +221,8 @@ func runFileRetrievalTest(nodeCount int) error {
212221 }
213222 })
214223
224+ log .Info ("Simulation terminated" )
225+
215226 if result .Error != nil {
216227 return result .Error
217228 }
0 commit comments