Skip to content

Commit

Permalink
feat: http NewMux coverage support
Browse files Browse the repository at this point in the history
  • Loading branch information
shoriwe committed Jun 11, 2023
1 parent cfd06c2 commit 8ebc623
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions utils/http/mux_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package http

import (
"testing"

"github.com/shoriwe/fullproxy/v3/utils/network"
)

func TestNewMux(t *testing.T) {
l := network.ListenAny()
defer l.Close()
checkCh := make(chan struct{}, 1)
defer close(checkCh)
go func() {
NewMux(l)
checkCh <- struct{}{}
}()
<-checkCh
}

0 comments on commit 8ebc623

Please sign in to comment.