etcd-io / raft

Raft library for maintaining a replicated state machine
Apache License 2.0
630 stars 160 forks source link

Test: Replace t.error/fatal with assert/request in [raft_test.go] #173

Closed MrDXY closed 6 months ago

MrDXY commented 6 months ago

Refactor: Replacing t.Error/t.Fatal with assert/require

This commit tries to eliminates boilerplate code in the testing suite by replacing occurrences of t.Error and t.Fatal with assertions from the assert and require packages.

Changes Made:

Affected Files:

Part of: #146

MrDXY commented 6 months ago

Thank you for your review. I must admit that I may have been a bit hasty in submitting this PR with multiple errors and inconsistencies. And I'll try to double-check everything before the next commit.