Skip to content

Commit a66e96c

Browse files
committed
storage_api: don't check raft status in test
This seems unrelated to the test. We don't actually guarantee that a single node raft group can't transition through StateCandidate; clearly it's possible. Via backports: Closes #148564. Epic: none
1 parent 32b9329 commit a66e96c

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

pkg/server/storage_api/ranges_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import (
1414
"github.com/cockroachdb/cockroach/pkg/keys"
1515
"github.com/cockroachdb/cockroach/pkg/kv/kvserver"
1616
"github.com/cockroachdb/cockroach/pkg/roachpb"
17-
"github.com/cockroachdb/cockroach/pkg/server"
1817
"github.com/cockroachdb/cockroach/pkg/server/serverpb"
1918
"github.com/cockroachdb/cockroach/pkg/server/srvtestutils"
2019
"github.com/cockroachdb/cockroach/pkg/testutils/serverutils"
@@ -56,9 +55,6 @@ func TestRangesResponse(t *testing.T) {
5655
for _, ri := range response.Ranges {
5756
// Do some simple validation based on the fact that this is a
5857
// single-node cluster.
59-
if ri.RaftState.State != "StateLeader" && ri.RaftState.State != server.RaftStateDormant {
60-
t.Errorf("expected to be Raft leader or dormant, but was '%s'", ri.RaftState.State)
61-
}
6258
expReplica := roachpb.ReplicaDescriptor{
6359
NodeID: 1,
6460
StoreID: 1,

0 commit comments

Comments
 (0)