forked from TrueCloudLab/frostfs-node
[#298] innerring: Fix broken tests
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
d00b1c0d29
commit
235fe84ea3
3 changed files with 14 additions and 67 deletions
|
@ -7,9 +7,7 @@ import (
|
|||
|
||||
v2netmap "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/netmap"
|
||||
netmapContract "git.frostfs.info/TrueCloudLab/frostfs-contract/netmap"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/innerring/processors/audit"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/innerring/processors/governance"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/innerring/processors/settlement"
|
||||
timerEvent "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/innerring/timers"
|
||||
cntClient "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/container"
|
||||
netmapclient "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/netmap"
|
||||
|
@ -84,8 +82,6 @@ func TestNewEpoch(t *testing.T) {
|
|||
proc, err := newTestProc(t, func(p *Params) {
|
||||
p.NotaryDisabled = true
|
||||
p.NotaryDepositHandler = eh.Handle
|
||||
p.HandleAudit = eh.Handle
|
||||
p.AuditSettlementsHandler = eh.Handle
|
||||
p.AlphabetSyncHandler = eh.Handle
|
||||
p.NetmapClient = nc
|
||||
p.ContainerWrapper = cc
|
||||
|
@ -115,8 +111,6 @@ func TestNewEpoch(t *testing.T) {
|
|||
require.EqualValues(t, []cntClient.StartEstimationPrm{expEstimation}, cc.estimations, "invalid estimations")
|
||||
|
||||
require.EqualValues(t, []event.Event{
|
||||
audit.NewAuditStartEvent(ev.Num),
|
||||
settlement.NewAuditEvent(ev.Num),
|
||||
governance.NewSyncEvent(ev.TxHash()),
|
||||
ev,
|
||||
}, eh.handledEvents, "invalid handled events")
|
||||
|
@ -409,22 +403,20 @@ func newTestProc(t *testing.T, nonDefault func(p *Params)) (*Processor, error) {
|
|||
eh := &testEventHandler{}
|
||||
|
||||
p := &Params{
|
||||
Log: test.NewLogger(t, true),
|
||||
PoolSize: 1,
|
||||
CleanupEnabled: false,
|
||||
CleanupThreshold: 3,
|
||||
NotaryDisabled: false,
|
||||
NodeStateSettings: ns,
|
||||
NodeValidator: &testValidator{},
|
||||
EpochState: es,
|
||||
EpochTimer: r,
|
||||
AlphabetState: as,
|
||||
ContainerWrapper: cc,
|
||||
NetmapClient: nc,
|
||||
NotaryDepositHandler: eh.Handle,
|
||||
HandleAudit: eh.Handle,
|
||||
AuditSettlementsHandler: eh.Handle,
|
||||
AlphabetSyncHandler: eh.Handle,
|
||||
Log: test.NewLogger(t, true),
|
||||
PoolSize: 1,
|
||||
CleanupEnabled: false,
|
||||
CleanupThreshold: 3,
|
||||
NotaryDisabled: false,
|
||||
NodeStateSettings: ns,
|
||||
NodeValidator: &testValidator{},
|
||||
EpochState: es,
|
||||
EpochTimer: r,
|
||||
AlphabetState: as,
|
||||
ContainerWrapper: cc,
|
||||
NetmapClient: nc,
|
||||
NotaryDepositHandler: eh.Handle,
|
||||
AlphabetSyncHandler: eh.Handle,
|
||||
}
|
||||
|
||||
nonDefault(p)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue