Skip to content

Commit

Permalink
storagefsm: Test fsmPlanners map
Browse files Browse the repository at this point in the history
  • Loading branch information
magik6k authored and codefather-filestar committed Jun 17, 2021
1 parent 12a2894 commit d59eed2
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions extern/storage-sealing/fsm_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,3 +160,18 @@ func TestPlanCommittingHandlesSectorCommitFailed(t *testing.T) {

require.Equal(t, CommitFailed, m.state.State)
}

func TestPlannerList(t *testing.T) {
for state := range ExistSectorStateList {
_, ok := fsmPlanners[state]
require.True(t, ok, "state %s", state)
}

for state := range fsmPlanners {
if state == UndefinedSectorState {
continue
}
_, ok := ExistSectorStateList[state]
require.True(t, ok, "state %s", state)
}
}

0 comments on commit d59eed2

Please sign in to comment.