From 26f049abc94e9c91e228e869ec9a7ed6e7f5b214 Mon Sep 17 00:00:00 2001 From: Thane Thomson Date: Mon, 11 Apr 2022 08:25:51 -0400 Subject: [PATCH] Expand on vote equality test errors for clarity Signed-off-by: Thane Thomson --- internal/consensus/common_test.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/internal/consensus/common_test.go b/internal/consensus/common_test.go index 756fa9eef..07c302f22 100644 --- a/internal/consensus/common_test.go +++ b/internal/consensus/common_test.go @@ -749,10 +749,9 @@ func ensureVote(t *testing.T, voteCh <-chan tmpubsub.Message, height int64, roun msg.Data()) vote := voteEvent.Vote - require.Equal(t, height, vote.Height) - require.Equal(t, round, vote.Round) - - require.Equal(t, voteType, vote.Type) + require.Equal(t, height, vote.Height, "expected height %d, but got %d", height, vote.Height) + require.Equal(t, round, vote.Round, "expected round %d, but got %d", round, vote.Round) + require.Equal(t, voteType, vote.Type, "expected type %s, but got %s", voteType, vote.Type) } func ensureNewEventOnChannel(t *testing.T, ch <-chan tmpubsub.Message) {