[#116] node: Fix bug with extra generated files in TestReload #220

Merged
fyrchik merged 1 commit from aarifullin/frostfs-node:fix/116-generated_extra_files into master 2023-04-06 07:02:43 +00:00

View file

@ -25,6 +25,7 @@ import (
"github.com/stretchr/testify/require"
"go.etcd.io/bbolt"
"go.uber.org/atomic"
"go.uber.org/zap"
"go.uber.org/zap/zaptest"
)
@ -321,8 +322,9 @@ func engineWithShards(t *testing.T, path string, num int) (*StorageEngine, []str
currShards := make([]string, 0, num)
te := testNewEngine(t).
setShardsNumAdditionalOpts(t, num, func(id int) []shard.Option {
Review

@dstepanov-yadro noticed that tests generate extra *.pilorama files. It turned out that default shards have set Pilorama option that led to generating extra *.pilorama files in TestReload

@dstepanov-yadro noticed that tests generate extra `*.pilorama` files. It turned out that default shards have set `Pilorama` option that led to generating extra `*.pilorama` files in `TestReload`
setShardsNumOpts(t, num, func(id int) []shard.Option {
return []shard.Option{
shard.WithLogger(&logger.Logger{Logger: zap.L()}),
shard.WithBlobStorOptions(
blobstor.WithStorages(newStorages(filepath.Join(addPath, strconv.Itoa(id)), errSmallSize))),
shard.WithMetaBaseOptions(