Files
chaisql/internal/testutil/debug.go
Asdine El Hrychy f1f933e49b update dependencies
2025-08-12 20:58:05 +08:00

22 lines
364 B
Go

package testutil
import (
"fmt"
"testing"
"github.com/cockroachdb/pebble/v2"
"github.com/stretchr/testify/require"
)
func DumpPebble(t testing.TB, pdb *pebble.DB) {
it, err := pdb.NewIter(nil)
require.NoError(t, err)
for it.First(); it.Valid(); it.Next() {
fmt.Printf("%v: %v\n", it.Key(), it.Value())
}
err = it.Close()
require.NoError(t, err)
}