tidy
This commit is contained in:
@@ -54,7 +54,7 @@ func downloadJar(url *url.URL, outputDir string) (string, error) {
|
||||
}
|
||||
}
|
||||
if uncompressedReader == nil {
|
||||
return "", fmt.Errorf("unable to find .deb data file")
|
||||
return "", errors.New("unable to find .deb data file")
|
||||
}
|
||||
|
||||
tarReader := tar.NewReader(uncompressedReader)
|
||||
@@ -86,7 +86,7 @@ func downloadJar(url *url.URL, outputDir string) (string, error) {
|
||||
}
|
||||
|
||||
if aceJar == nil {
|
||||
return "", fmt.Errorf("unable to find ace.jar")
|
||||
return "", errors.New("unable to find ace.jar")
|
||||
}
|
||||
|
||||
defer aceJar.Close()
|
||||
@@ -192,7 +192,6 @@ func extractJSON(jarFile, fieldsDir string) error {
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to read file: %w", err)
|
||||
}
|
||||
|
||||
}
|
||||
fmt.Println(file.Name(), file.IsDir())
|
||||
}
|
||||
|
||||
@@ -151,7 +151,7 @@ func TestResourceTypes(t *testing.T) {
|
||||
|
||||
err := resource.processJSON(([]byte)(testData))
|
||||
|
||||
assert.Empty(t, err, "No error processing JSON")
|
||||
assert.NoError(t, err, "No error processing JSON")
|
||||
assert.Equal(t, expectation.StructName, resource.StructName)
|
||||
assert.Equal(t, expectation.ResourcePath, resource.ResourcePath)
|
||||
assert.Equal(t, expectation.Types, resource.Types)
|
||||
|
||||
Reference in New Issue
Block a user