test

package
v2.14.1 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTestToken

func GetTestToken() string

Types

type Handler added in v2.6.1

type Handler func(w http.ResponseWriter, r *http.Request)

type ServerTest

type ServerTest struct {
	// contains filtered or unexported fields
}

func NewTestServer

func NewTestServer() *ServerTest

func (*ServerTest) AnthropicTestServer

func (ts *ServerTest) AnthropicTestServer() *httptest.Server

AnthropicTestServer Creates a mocked Anthropic server which can pretend to handle requests during testing.

func (*ServerTest) RegisterHandler

func (ts *ServerTest) RegisterHandler(path string, handler Handler)

func (*ServerTest) VertexTestServer added in v2.12.0

func (ts *ServerTest) VertexTestServer() *httptest.Server

VertexTestServer Creates a mocked Vertex Anthropic server which can pretend to handle requests during testing.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳