diff --git a/plugin/converter/template.go b/plugin/converter/template.go index cb83a2f5..5a238544 100644 --- a/plugin/converter/template.go +++ b/plugin/converter/template.go @@ -19,7 +19,7 @@ var ( 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{ templateStore: templateStore, } diff --git a/plugin/converter/template_test.go b/plugin/converter/template_test.go index 3073cf85..0a0bf2c7 100644 --- a/plugin/converter/template_test.go +++ b/plugin/converter/template_test.go @@ -38,7 +38,7 @@ func TestTemplatePluginConvert(t *testing.T) { templates := mock.NewMockTemplateStore(controller) templates.EXPECT().FindName(gomock.Any(), template.Name).Return(template, nil) - plugin := TemplateConverter(templates) + plugin := Template(templates) req := &core.ConvertArgs{ Build: &core.Build{ After: "3d21ec53a331a6f037a91c368710b99387d012c1", @@ -70,7 +70,7 @@ func TestTemplatePluginConvert(t *testing.T) { func TestTemplatePluginConvertNotYamlFile(t *testing.T) { - plugin := TemplateConverter(nil) + plugin := Template(nil) req := &core.ConvertArgs{ Build: &core.Build{ After: "3d21ec53a331a6f037a91c368710b99387d012c1", @@ -98,7 +98,7 @@ func TestTemplatePluginConvertDroneFileTypePipeline(t *testing.T) { t.Error(err) return } - plugin := TemplateConverter(nil) + plugin := Template(nil) req := &core.ConvertArgs{ Build: &core.Build{ After: "3d21ec53a331a6f037a91c368710b99387d012c1", @@ -138,7 +138,7 @@ func TestTemplatePluginConvertTemplateNotFound(t *testing.T) { return } - plugin := TemplateConverter(templates) + plugin := Template(templates) req := &core.ConvertArgs{ Build: &core.Build{ After: "3d21ec53a331a6f037a91c368710b99387d012c1",