Skip to content

Commit

Permalink
fixed method name
Browse files Browse the repository at this point in the history
  • Loading branch information
hellt committed Jun 30, 2021
1 parent fa1d4e1 commit 2e2fcdf
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions clab/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ func (c *CLab) createNodeCfg(nodeName string, nodeDef *types.NodeDefinition, idx
log.Debugf("node config: %+v", nodeCfg)
var err error
// initialize config
nodeCfg.StartupConfig, err = c.Config.Topology.GetNodeConfig(nodeCfg.ShortName)
nodeCfg.StartupConfig, err = c.Config.Topology.GetNodeStartupConfig(nodeCfg.ShortName)
if err != nil {
return nil, err
}
Expand Down Expand Up @@ -221,7 +221,7 @@ func (c *CLab) NewEndpoint(e string) *types.Endpoint {
if len(endpoint.EndpointName) > 15 {
log.Fatalf("interface '%s' name exceeds maximum length of 15 characters", endpoint.EndpointName)
}
// generate unqiue MAC
// generate unique MAC
endpoint.MAC = utils.GenMac(clabOUI)

// search the node pointer for a node name referenced in endpoint section
Expand Down
2 changes: 1 addition & 1 deletion types/topology.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ func (t *Topology) GetNodeLabels(name string) map[string]string {
return nil
}

func (t *Topology) GetNodeConfig(name string) (string, error) {
func (t *Topology) GetNodeStartupConfig(name string) (string, error) {
var cfg string
if ndef, ok := t.Nodes[name]; ok {
var err error
Expand Down
2 changes: 1 addition & 1 deletion types/topology_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ func TestGetNodeType(t *testing.T) {
func TestGetNodeConfig(t *testing.T) {
for name, item := range topologyTestSet {
t.Logf("%q test item", name)
config, err := item.input.GetNodeConfig("node1")
config, err := item.input.GetNodeStartupConfig("node1")
if err != nil {
t.Fatal(err)
}
Expand Down

0 comments on commit 2e2fcdf

Please sign in to comment.