Small bug fix - renaming converter back to template
This commit is contained in:
parent
8b7933c116
commit
a7ef135403
2 changed files with 5 additions and 5 deletions
|
@ -19,7 +19,7 @@ var (
|
||||||
ErrTemplateSyntaxErrors = errors.New("template converter: there is a problem with the yaml file provided")
|
ErrTemplateSyntaxErrors = errors.New("template converter: there is a problem with the yaml file provided")
|
||||||
)
|
)
|
||||||
|
|
||||||
func TemplateConverter(templateStore core.TemplateStore) core.ConvertService {
|
func Template(templateStore core.TemplateStore) core.ConvertService {
|
||||||
return &templatePlugin{
|
return &templatePlugin{
|
||||||
templateStore: templateStore,
|
templateStore: templateStore,
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,7 @@ func TestTemplatePluginConvert(t *testing.T) {
|
||||||
templates := mock.NewMockTemplateStore(controller)
|
templates := mock.NewMockTemplateStore(controller)
|
||||||
templates.EXPECT().FindName(gomock.Any(), template.Name).Return(template, nil)
|
templates.EXPECT().FindName(gomock.Any(), template.Name).Return(template, nil)
|
||||||
|
|
||||||
plugin := TemplateConverter(templates)
|
plugin := Template(templates)
|
||||||
req := &core.ConvertArgs{
|
req := &core.ConvertArgs{
|
||||||
Build: &core.Build{
|
Build: &core.Build{
|
||||||
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
||||||
|
@ -70,7 +70,7 @@ func TestTemplatePluginConvert(t *testing.T) {
|
||||||
|
|
||||||
func TestTemplatePluginConvertNotYamlFile(t *testing.T) {
|
func TestTemplatePluginConvertNotYamlFile(t *testing.T) {
|
||||||
|
|
||||||
plugin := TemplateConverter(nil)
|
plugin := Template(nil)
|
||||||
req := &core.ConvertArgs{
|
req := &core.ConvertArgs{
|
||||||
Build: &core.Build{
|
Build: &core.Build{
|
||||||
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
||||||
|
@ -98,7 +98,7 @@ func TestTemplatePluginConvertDroneFileTypePipeline(t *testing.T) {
|
||||||
t.Error(err)
|
t.Error(err)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
plugin := TemplateConverter(nil)
|
plugin := Template(nil)
|
||||||
req := &core.ConvertArgs{
|
req := &core.ConvertArgs{
|
||||||
Build: &core.Build{
|
Build: &core.Build{
|
||||||
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
||||||
|
@ -138,7 +138,7 @@ func TestTemplatePluginConvertTemplateNotFound(t *testing.T) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
plugin := TemplateConverter(templates)
|
plugin := Template(templates)
|
||||||
req := &core.ConvertArgs{
|
req := &core.ConvertArgs{
|
||||||
Build: &core.Build{
|
Build: &core.Build{
|
||||||
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
After: "3d21ec53a331a6f037a91c368710b99387d012c1",
|
||||||
|
|
Loading…
Reference in a new issue