Skip to content

Commit a3f0e0a

Browse files
committed
test: error msg change
1 parent c783d83 commit a3f0e0a

2 files changed

Lines changed: 5 additions & 7 deletions

File tree

pkg/analysis/passes/metadatavalid/metadatavalid.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,7 @@ func run(pass *analysis.Pass) (interface{}, error) {
9292
if pluginJsonBytes != nil {
9393
var data metadata.Metadata
9494
if err := json.Unmarshal(pluginJsonBytes, &data); err == nil {
95-
fmt.Println(data.Dependencies.GrafanaDependency)
9695
_, err = version.NewConstraint(data.Dependencies.GrafanaDependency)
97-
fmt.Println(err)
9896
if err != nil {
9997
pass.ReportResult(
10098
pass.AnalyzerName,

pkg/cmd/plugincheck2/main_test.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ func TestIntegration(t *testing.T) {
258258
"metadatavalid": {
259259
{
260260
Severity: "error",
261-
Title: "plugin.json: dependencies: grafanaDependency is required",
261+
Title: "plugin.json: Dependencies.grafanaDependency field has invalid or empty version constraint:",
262262
Detail: "The plugin.json file is not following the schema. Please refer to the documentation for more information. https://grafana.com/docs/grafana/latest/developers/plugins/metadata/",
263263
Name: "invalid-metadata",
264264
},
@@ -317,8 +317,8 @@ func TestIntegration(t *testing.T) {
317317
"metadatavalid": {
318318
{
319319
Severity: "error",
320-
Title: "plugin.json: dependencies: grafanaDependency is required",
321-
Detail: "The plugin.json file is not following the schema. Please refer to the documentation for more information. https://grafana.com/docs/grafana/latest/developers/plugins/metadata/",
320+
Title: "plugin.json: Dependencies.grafanaDependency field has invalid or empty version constraint:",
321+
Detail: "Please refer to the documentation for more information. https://grafana.com/docs/grafana/latest/developers/plugins/metadata/#grafanadependency",
322322
Name: "invalid-metadata",
323323
},
324324
},
@@ -336,8 +336,8 @@ func TestIntegration(t *testing.T) {
336336
"metadatavalid": {
337337
{
338338
Severity: "warning",
339-
Title: "plugin.json: dependencies: grafanaDependency is required",
340-
Detail: "The plugin.json file is not following the schema. Please refer to the documentation for more information. https://grafana.com/docs/grafana/latest/developers/plugins/metadata/",
339+
Title: "plugin.json: Dependencies.grafanaDependency field has invalid or empty version constraint:",
340+
Detail: "Please refer to the documentation for more information. https://grafana.com/docs/grafana/latest/developers/plugins/metadata/#grafanadependency",
341341
Name: "invalid-metadata",
342342
},
343343
},

0 commit comments

Comments
 (0)