v1

package
v2.0.0-...-a7294fb Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2024 License: MIT Imports: 19 Imported by: 0

README

Legacy support for go-vcr v1

To avoid having to re-record all our tests in one go, this package provides legacy support for go-vcr v1 recordings.

Once we have migrated all recordings to the new format (as required by go-vcr v3), this package will be removed.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var COUNT_HEADER string = "TEST-REQUEST-ATTEMPT"

Functions

func AddCountHeader

func AddCountHeader(inner http.RoundTripper) *requestCounter

func CassetteFileExists

func CassetteFileExists(cassetteName string) (bool, error)

CassetteFileExists returns true if a cassette file exists AND it contains a go-vcr V1 recording

func NewTestPlayer

func NewTestPlayer(
	cassetteName string,
	cfg config.Values,
) (vcr.Interface, error)

NewTestPlayer creates a TestRecorder that can be used to replay test recorded with go-vcr v1. cassetteName is the name of the cassette file to replay. cfg is the configuration to use when replaying the test.

Types

This section is empty.

Jump to

Keyboard shortcuts

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