Skip to content

Commit

Permalink
Add websockets unit tests and wrap gorilla library (#892)
Browse files Browse the repository at this point in the history
Co-authored-by: matoval <[email protected]>
  • Loading branch information
AaronH88 and matoval authored Nov 8, 2023
1 parent 8a8cee2 commit e2c1090
Show file tree
Hide file tree
Showing 6 changed files with 928 additions and 29 deletions.
2 changes: 1 addition & 1 deletion packaging/container/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM quay.io/centos/centos:stream9 as builder
ARG VERSION

RUN dnf -y update && dnf install -y golang make python3 python3-pip git
RUN dnf -y update && dnf install -y 'golang <= 1.21.0' make python3 python3-pip git
RUN pip install wheel

ADD source.tar.gz /source
Expand Down
356 changes: 356 additions & 0 deletions pkg/backends/mock_backends/websockets.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/backends/websocket_interop_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func TestWebsocketExternalInterop(t *testing.T) {
MinVersion: tls.VersionTLS12,
CurvePreferences: []tls.CurveID{tls.CurveP521, tls.CurveP384, tls.CurveP256},
}
b2, err := NewWebsocketDialer("wss://"+li.Addr().String(), tls2, "X-Extra-Data: SomeData", true, n1.Logger)
b2, err := NewWebsocketDialer("wss://"+li.Addr().String(), tls2, "X-Extra-Data: SomeData", true, n1.Logger, nil)
if err != nil {
t.Fatal(err)
}
Expand Down
Loading

0 comments on commit e2c1090

Please sign in to comment.