server: test invalid paths

This commit is contained in:
aler9
2021-05-08 16:01:06 +02:00
parent 028ed2b973
commit 11a5fb68ad
4 changed files with 174 additions and 24 deletions

View File

@@ -77,12 +77,12 @@ func (e ErrServerWrongState) Error() string {
e.AllowedList, e.State)
}
// ErrServerNoPath is an error that can be returned by a server.
type ErrServerNoPath struct{}
// ErrServerInvalidPath is an error that can be returned by a server.
type ErrServerInvalidPath struct{}
// Error implements the error interface.
func (e ErrServerNoPath) Error() string {
return "RTSP path can't be retrieved"
func (e ErrServerInvalidPath) Error() string {
return "invalid path"
}
// ErrServerContentTypeMissing is an error that can be returned by a server.