integration testing scripts #64
2 changed files with 8 additions and 1 deletions
4
db/db.go
4
db/db.go
|
@ -606,6 +606,8 @@ func GetDBColumnFamilies(name string, secondayPath string, cfNames []string) (*R
|
|||
LastState: nil,
|
||||
Height: 0,
|
||||
Headers: nil,
|
||||
OpenIterators: make(map[string][]chan struct{}),
|
||||
ItMut: sync.RWMutex{},
|
||||
ShutdownChan: make(chan struct{}, 1),
|
||||
DoneChan: make(chan struct{}, 1),
|
||||
}
|
||||
|
@ -1080,7 +1082,7 @@ func GenerateTestData(prefix byte, fileName string) {
|
|||
log.Fatalln(err)
|
||||
}
|
||||
|
||||
options := NewIterateOptions().WithDB(db)
|
||||
options := NewIterateOptions()
|
||||
options.WithRawKey(true).WithRawValue(true).WithIncludeValue(true)
|
||||
options.WithPrefix([]byte{prefix})
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@ import (
|
|||
"log"
|
||||
"os"
|
||||
"strings"
|
||||
"sync"
|
||||
"testing"
|
||||
|
||||
dbpkg "github.com/lbryio/herald.go/db"
|
||||
|
@ -93,6 +94,10 @@ func OpenAndFillTmpDBColumnFamlies(filePath string) (*dbpkg.ReadOnlyDBColumnFami
|
|||
LastState: nil,
|
||||
Height: 0,
|
||||
Headers: nil,
|
||||
OpenIterators: make(map[string][]chan struct{}),
|
||||
ItMut: sync.RWMutex{},
|
||||
ShutdownChan: make(chan struct{}, 1),
|
||||
DoneChan: make(chan struct{}, 1),
|
||||
}
|
||||
|
||||
// err = dbpkg.ReadDBState(myDB) //TODO: Figure out right place for this
|
||||
|
|
Loading…
Reference in a new issue