rts-sim-module/repository/repository_manager_test.go
2023-09-20 15:16:36 +08:00

23 lines
419 B
Go

package repository
import (
"google.golang.org/protobuf/proto"
proto2 "joylink.club/rtsssimulation/repository/model/proto"
"os"
"testing"
)
func TestBuildRepository(t *testing.T) {
bytes, err := os.ReadFile("./repo.bin")
if err != nil {
panic(err)
}
source := &proto2.Repository{}
err = proto.Unmarshal(bytes, source)
if err != nil {
panic(err)
}
repo, err := BuildRepository(source)
println(repo)
}