Unified Storage: Update yaml decoding for quotas to accomodate top-level overrides key (#115049)

* update yaml decoding for quotas to accomodate top-level overrides key

* update test

* fix test indentation
This commit is contained in:
owensmallwood
2025-12-09 23:14:22 +00:00
committed by GitHub
parent ff43c175c8
commit 6b50e2d730
3 changed files with 90 additions and 74 deletions
+5 -4
View File
@@ -643,10 +643,11 @@ func TestGetQuotaUsage(t *testing.T) {
t.Run("returns usage and limit successfully", func(t *testing.T) {
// Create a temporary overrides config file
tmpFile := filepath.Join(t.TempDir(), "overrides.yaml")
content := `"123":
quotas:
dashboard.grafana.app/dashboards:
limit: 500
content := `overrides:
"123":
quotas:
dashboard.grafana.app/dashboards:
limit: 500
`
require.NoError(t, os.WriteFile(tmpFile, []byte(content), 0644))