aboutsummaryrefslogtreecommitdiff
path: root/config_test.go
diff options
context:
space:
mode:
authorGravatar Abhinav Gupta <mail@abhinavg.net> 2023-01-23 09:25:18 -0800
committerGravatar GitHub <noreply@github.com> 2023-01-23 09:25:18 -0800
commit24b0c32c0a0aeabc2131361f9bacaeaec8988ada (patch)
tree629330cafa35477c87f13398b49260ceb73bfb65 /config_test.go
parentbdce05d68305442e0214f80b08faf20dd12c0e25 (diff)
downloadsally-24b0c32c0a0aeabc2131361f9bacaeaec8988ada.tar.gz
sally-24b0c32c0a0aeabc2131361f9bacaeaec8988ada.tar.zst
sally-24b0c32c0a0aeabc2131361f9bacaeaec8988ada.zip
config: Don't require packages to be alphabetical (#66)
The configuration parser requries that entries in the 'packages' section are in alphabetical order. It will fail parsing if that's not the case, even if the configuration is otherwise valid. This seems like an unnecessary artificial limitation. Enforcing such a convention should be the user's choice. This change deletes this limitation.
Diffstat (limited to 'config_test.go')
-rw-r--r--config_test.go19
1 files changed, 0 insertions, 19 deletions
diff --git a/config_test.go b/config_test.go
index eb6c463..e4146b1 100644
--- a/config_test.go
+++ b/config_test.go
@@ -106,22 +106,3 @@ packages:
})
}
}
-
-func TestNotAlphabetical(t *testing.T) {
- path, clean := TempFile(t, `
-
-url: google.golang.org
-packages:
- grpc:
- repo: github.com/grpc/grpc-go
- atomic:
- repo: github.com/uber-go/atomic
-
-`)
- defer clean()
-
- _, err := Parse(path)
- if assert.Error(t, err, "YAML configuration is not listed alphabetically") {
- assert.Contains(t, err.Error(), "must be alphabetically ordered")
- }
-}