Skip to content

Commit

Permalink
fix unit test TestCopyTemplateFiles
Browse files Browse the repository at this point in the history
  • Loading branch information
yuanhao authored and howieyuen committed Jun 9, 2022
1 parent e8dca14 commit 5df300d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions pkg/scaffold/external_templates_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,9 @@ func TestCopyTemplateFiles(t *testing.T) {
}
stack2Configs[stack.Name] = configs
}
// project name
projectName := localTemplate.ProjectName
err = CopyTemplateFiles(localRoot, tmp, true, projectName, projectConfigs, stack2Configs)
err = CopyTemplateFiles(localTemplate.Dir, tmp, true, localTemplate.ProjectName, projectConfigs, stack2Configs)
if err != nil {
fmt.Printf("err: %v", err)
}
assert.Nil(t, err)
}
2 changes: 1 addition & 1 deletion pkg/scaffold/project.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const (
BoolField FieldType = "bool"
FloatField FieldType = "float"
ArrayField FieldType = "array"
StructField FieldType = "struct"
MapField FieldType = "map"
)

func (f FieldType) IsPrimitive() bool {
Expand Down

0 comments on commit 5df300d

Please sign in to comment.