mirror of
https://github.com/tendermint/tendermint.git
synced 2026-02-03 18:42:14 +00:00
* Rebased and git-squashed the commits in PR #6546 migrate abci to finalizeBlock work on abci, proxy and mempool abciresponse, blok events, indexer, some tests fix some tests fix errors fix errors in abci fix tests amd errors * Fixes after rebasing PR#6546 * Restored height to RequestFinalizeBlock & other * Fixed more UTs * Fixed kvstore * More UT fixes * last TC fixed * make format * Update internal/consensus/mempool_test.go Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com> * Addressed @williambanfield's comments * Fixed UTs * Addressed last comments from @williambanfield * make format Co-authored-by: marbar3778 <marbar3778@yahoo.com> Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com>
35 lines
705 B
Go
35 lines
705 B
Go
package server_test
|
|
|
|
import (
|
|
"io"
|
|
"os"
|
|
"path/filepath"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
|
|
"github.com/tendermint/tendermint/test/fuzz/rpc/jsonrpc/server"
|
|
)
|
|
|
|
const testdataCasesDir = "testdata/cases"
|
|
|
|
func TestServerTestdataCases(t *testing.T) {
|
|
entries, err := os.ReadDir(testdataCasesDir)
|
|
require.NoError(t, err)
|
|
|
|
for _, e := range entries {
|
|
entry := e
|
|
t.Run(entry.Name(), func(t *testing.T) {
|
|
defer func() {
|
|
r := recover()
|
|
require.Nilf(t, r, "testdata/cases test panic")
|
|
}()
|
|
f, err := os.Open(filepath.Join(testdataCasesDir, entry.Name()))
|
|
require.NoError(t, err)
|
|
input, err := io.ReadAll(f)
|
|
require.NoError(t, err)
|
|
server.Fuzz(input)
|
|
})
|
|
}
|
|
}
|