test: add test for convert command

This commit is contained in:
Antoine Aflalo
2024-08-27 09:10:50 -04:00
parent 7d839e8868
commit 128a981f91
2 changed files with 104 additions and 1 deletions

View File

@@ -27,7 +27,9 @@ func Available() []constant.ConversionFormat {
// Get returns a packer by name.
// If the packer is not available, an error is returned.
func Get(name constant.ConversionFormat) (Converter, error) {
var Get = getConverter
func getConverter(name constant.ConversionFormat) (Converter, error) {
if converter, ok := converters[name]; ok {
return converter, nil
}