refactor(netxlite): restructure dialer tests (#486)
While there, add one more test checking for whether the internal CA bundle we use can actually be loaded. Part of https://github.com/ooni/probe/issues/1591
This commit is contained in:
parent
f054ec3201
commit
6d39118b26
6 changed files with 297 additions and 239 deletions
13
internal/netxlite/certifi_test.go
Normal file
13
internal/netxlite/certifi_test.go
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
package netxlite
|
||||
|
||||
import (
|
||||
"crypto/x509"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestPEMCerts(t *testing.T) {
|
||||
pool := x509.NewCertPool()
|
||||
if !pool.AppendCertsFromPEM([]byte(pemcerts)) {
|
||||
t.Fatal("cannot load pemcerts")
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue