networktest

package
v0.5.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 25, 2026 License: MIT Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package networktest holds test helpers for transports built on pkg/core/network.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertResumes

func AssertResumes(t testing.TB, client *http.Client)

AssertResumes sends three GETs through client to a ResumeServer and fails unless the first did a full handshake and the second and third resumed.

func CheckResumed

func CheckResumed(t testing.TB, got []bool)

CheckResumed fails unless got is [false true true]: one full handshake, then two resumed sessions.

func ResumeServer

func ResumeServer(t testing.TB) (url string, resumed func() []bool)

ResumeServer starts a TLS server that closes every connection after one response, so each request is a new handshake, and records whether each handshake resumed a session. It is stopped at test cleanup.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL