mirror of
https://github.com/davidallendj/configurator.git
synced 2025-12-19 19:17:01 -07:00
examples: updated test plugin
This commit is contained in:
parent
cd40fd194f
commit
733c486cb2
1 changed files with 5 additions and 1 deletions
|
|
@ -13,7 +13,11 @@ func (g *TestGenerator) GetDescription() string {
|
||||||
return "This is a plugin creating for running tests."
|
return "This is a plugin creating for running tests."
|
||||||
}
|
}
|
||||||
func (g *TestGenerator) Generate(config *config.Config, params generator.Params) (generator.FileMap, error) {
|
func (g *TestGenerator) Generate(config *config.Config, params generator.Params) (generator.FileMap, error) {
|
||||||
return generator.FileMap{"test": []byte("test")}, nil
|
return generator.ApplyTemplates(generator.Mappings{
|
||||||
|
"plugin_name": g.GetName(),
|
||||||
|
"plugin_version": g.GetVersion(),
|
||||||
|
"plugin_description": g.GetDescription(),
|
||||||
|
}, params.Templates)
|
||||||
}
|
}
|
||||||
|
|
||||||
var Generator TestGenerator
|
var Generator TestGenerator
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue