mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
cmd/swarm/swarm-smoke: trigger debug even on successful smoke runs
This commit is contained in:
parent
d9a6f0989b
commit
0fd51f1e01
1 changed files with 10 additions and 2 deletions
|
|
@ -44,7 +44,7 @@ func uploadAndSyncCmd(ctx *cli.Context, tuid string) error {
|
|||
errc := make(chan error)
|
||||
|
||||
go func() {
|
||||
errc <- uplaodAndSync(ctx, randomBytes, tuid)
|
||||
errc <- uploadAndSync(ctx, randomBytes, tuid)
|
||||
}()
|
||||
|
||||
select {
|
||||
|
|
@ -65,6 +65,14 @@ func uploadAndSyncCmd(ctx *cli.Context, tuid string) error {
|
|||
|
||||
return e
|
||||
}
|
||||
|
||||
// trigger debug functionality on randomBytes even on successful runs
|
||||
err := trackChunks(randomBytes[:])
|
||||
if err != nil {
|
||||
log.Error(err.Error())
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func trackChunks(testData []byte) error {
|
||||
|
|
@ -134,7 +142,7 @@ func getAllRefs(testData []byte) (storage.AddressCollection, error) {
|
|||
return fileStore.GetAllReferences(ctx, reader, false)
|
||||
}
|
||||
|
||||
func uplaodAndSync(c *cli.Context, randomBytes []byte, tuid string) error {
|
||||
func uploadAndSync(c *cli.Context, randomBytes []byte, tuid string) error {
|
||||
log.Info("uploading to "+httpEndpoint(hosts[0])+" and syncing", "tuid", tuid, "seed", seed)
|
||||
|
||||
t1 := time.Now()
|
||||
|
|
|
|||
Loading…
Reference in a new issue