Skip to content

Commit 21df8ed

Browse files
authored
Merge pull request #330 from SUNET/masv/test/integration
Fallback to empty cert pool and log it.
2 parents 7fa8dbb + 3929ffb commit 21df8ed

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

internal/wallet/integration/stack_test.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,9 @@ func TestMain(m *testing.M) {
8787
fmt.Fprintf(os.Stderr, "reading rootCA %s: %v\n", caPath, err)
8888
os.Exit(1)
8989
}
90-
pool, _ := x509.SystemCertPool()
91-
if pool == nil {
90+
pool, err := x509.SystemCertPool()
91+
if err != nil {
92+
fmt.Fprintf(os.Stderr, "loading system cert pool: %v; falling back to empty pool\n", err)
9293
pool = x509.NewCertPool()
9394
}
9495
if !pool.AppendCertsFromPEM(caPEM) {

0 commit comments

Comments
 (0)