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

@ -3,12 +3,12 @@ package gstructs_test
import (
"testing"
"github.com/dragonheim/gagent/internal/gstructs"
gs "github.com/dragonheim/gagent/internal/gstructs"
"github.com/stretchr/testify/assert"
)
func TestGetByIndex(t *testing.T) {
agentStatuses := gstructs.AgentStatuses
agentStatuses := gs.AgentStatuses
tests := []struct {
index int
@ -34,7 +34,7 @@ func TestGetByIndex(t *testing.T) {
}
func TestGetByName(t *testing.T) {
agentStatuses := gstructs.AgentStatuses
agentStatuses := gs.AgentStatuses
tests := []struct {
name string

View file

@ -3,11 +3,11 @@ package gstructs_test
import (
"testing"
"github.com/dragonheim/gagent/internal/gstructs"
gs "github.com/dragonheim/gagent/internal/gstructs"
)
func TestGagentConfig(t *testing.T) {
config := gstructs.GagentConfig{
config := gs.GagentConfig{
Name: "test-config",
Mode: "client",
UUID: "test-uuid",
@ -17,13 +17,13 @@ func TestGagentConfig(t *testing.T) {
ClientPort: 1234,
RouterPort: 5678,
WorkerPort: 9012,
Clients: []*gstructs.ClientDetails{
Clients: []*gs.ClientDetails{
{
ClientName: "test-client",
ClientID: "client-id",
},
},
Routers: []*gstructs.RouterDetails{
Routers: []*gs.RouterDetails{
{
RouterName: "test-router",
RouterID: "router-id",
@ -34,7 +34,7 @@ func TestGagentConfig(t *testing.T) {
WorkerPort: 9012,
},
},
Workers: []*gstructs.WorkerDetails{
Workers: []*gs.WorkerDetails{
{
WorkerName: "test-worker",
WorkerID: "worker-id",
@ -57,7 +57,7 @@ func TestGagentConfig(t *testing.T) {
}
func TestAgentDetails(t *testing.T) {
agent := gstructs.AgentDetails{
agent := gs.AgentDetails{
Status: 1,
Client: "test-client",
Shasum: "123456789abcdef",