minor cleanup and standardization of package names.

This commit is contained in:
James Wells 2023-06-30 17:47:45 -07:00
parent 3bb7096625
commit d13a309593
Signed by: jwells
GPG key ID: 73196D10B8E65666
9 changed files with 38 additions and 38 deletions

View file

@ -7,7 +7,8 @@ import (
log "log"
time "time"
gstructs "github.com/dragonheim/gagent/internal/gstructs"
gs "github.com/dragonheim/gagent/internal/gstructs"
cty "github.com/zclconf/go-cty/cty"
hclsimple "github.com/hashicorp/hcl/v2/hclsimple"
@ -19,11 +20,11 @@ type GagentDb struct {
}
type GagentDbRow struct {
Timestamp time.Time `hcl:"timestamp"`
DBName string `hcl:"chainid,optional"`
Agent gstructs.AgentDetails `hcl:"agent,block"`
DbCurrHash [32]byte `hcl:"currhash"`
DbPrevHash [32]byte `hcl:"prevhash"`
Timestamp time.Time `hcl:"timestamp"`
DBName string `hcl:"chainid,optional"`
Agent gs.AgentDetails `hcl:"agent,block"`
DbCurrHash [32]byte `hcl:"currhash"`
DbPrevHash [32]byte `hcl:"prevhash"`
}
/*

View file

@ -6,7 +6,7 @@ import (
"testing"
"time"
gstructs "github.com/dragonheim/gagent/internal/gstructs"
gs "github.com/dragonheim/gagent/internal/gstructs"
)
const testChainDBPath = "/tmp/test_chaindb.hcl"
@ -18,7 +18,7 @@ func TestGagentDb(t *testing.T) {
// Add a row to the database
row := &GagentDbRow{
DBName: "testDB",
Agent: gstructs.AgentDetails{
Agent: gs.AgentDetails{
Client: "testAgent",
Shasum: "v1.0.0",
},