versionsapi: allow debug stream

Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
Paul Meyer 2022-12-02 16:59:09 +01:00
parent 9c9c8e3d46
commit 8c5fc7a890
2 changed files with 34 additions and 2 deletions

View file

@ -277,3 +277,22 @@ func minorList() *List {
},
}
}
func TestIsValidStream(t *testing.T) {
testCases := map[string]bool{
"stable": true,
"debug": true,
"beta": false,
"alpha": false,
"unknown": false,
"fast": false,
}
for name, want := range testCases {
t.Run(name, func(t *testing.T) {
assert := assert.New(t)
assert.Equal(want, IsValidStream(name))
})
}
}