Skip to content

Commit

Permalink
Add server name to E2E tests
Browse files Browse the repository at this point in the history
Added server name to E2E tests in order to test SNI and avoid
some OpenSSL warning messages.
  • Loading branch information
igolaizola committed Feb 24, 2020
1 parent 3ccadad commit 3522807
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions e2e/e2e_openssl_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ func clientOpenSSL(c *comm) {
args := []string{"s_client",
"-dtls1_2",
"-quiet",
"-servername=localhost",
fmt.Sprintf("-connect=127.0.0.1:%d", c.serverPort),
}
ciphers := ciphersOpenSSL(cfg)
Expand Down
4 changes: 2 additions & 2 deletions e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ func testPionE2ESimple(t *testing.T, server, client func(*comm)) {
ctx, cancel := context.WithTimeout(context.Background(), 2*time.Second)
defer cancel()

cert, err := selfsign.GenerateSelfSigned()
cert, err := selfsign.GenerateSelfSignedWithDNS("localhost")
if err != nil {
t.Fatal(err)
}
Expand Down Expand Up @@ -301,7 +301,7 @@ func testPionE2EMTUs(t *testing.T, server, client func(*comm)) {
ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second)
defer cancel()

cert, err := selfsign.GenerateSelfSigned()
cert, err := selfsign.GenerateSelfSignedWithDNS("localhost")
if err != nil {
t.Fatal(err)
}
Expand Down

0 comments on commit 3522807

Please sign in to comment.