github.com/turingchain2020/turingchain@v1.1.21/types/key_test.go (about)

     1  package types
     2  
     3  import (
     4  	"testing"
     5  
     6  	"github.com/stretchr/testify/assert"
     7  )
     8  
     9  func TestKeyCreate(t *testing.T) {
    10  	assert.Equal(t, TotalFeeKey([]byte("1")), []byte("TotalFeeKey:1"))
    11  	assert.Equal(t, CalcLocalPrefix([]byte("1")), []byte("LODB-1-"))
    12  	assert.Equal(t, CalcStatePrefix([]byte("1")), []byte("mavl-1-"))
    13  	assert.Equal(t, CalcRollbackKey([]byte("execer"), []byte("1")), []byte("LODB-execer-rollback-1"))
    14  	assert.Equal(t, StatisticFlag(), []byte("Statistics:Flag"))
    15  }