1
0
Fork 0
forked from External/mediamtx

add JWT authentication tests (#3272)

This commit is contained in:
Alessandro Ros 2024-04-18 22:58:37 +02:00 committed by GitHub
parent 9d82d4e783
commit b84f0b90d0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 149 additions and 88 deletions

View file

@ -79,10 +79,11 @@ func TestSource(t *testing.T) {
require.NoError(t, err)
})
s := &http.Server{Handler: router}
ln, err := net.Listen("tcp", "localhost:5780")
require.NoError(t, err)
s := &http.Server{Handler: router}
go s.Serve(ln)
defer s.Shutdown(context.Background())