Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CameraCapture ¶
type CameraCapture struct {
CameraName string
Exchanges []CapturedExchange
}
CameraCapture holds all captured exchanges for a camera
func LoadCaptureFromArchive ¶
func LoadCaptureFromArchive(archivePath string) (*CameraCapture, error)
LoadCaptureFromArchive loads all captured exchanges from a tar.gz archive
type CapturedExchange ¶
type CapturedExchange struct {
Timestamp string `json:"timestamp"`
Operation int `json:"operation"`
OperationName string `json:"operation_name,omitempty"`
Endpoint string `json:"endpoint"`
RequestBody string `json:"request_body"`
ResponseBody string `json:"response_body"`
StatusCode int `json:"status_code"`
Error string `json:"error,omitempty"`
}
CapturedExchange represents a single SOAP request/response pair
type MockSOAPServer ¶
type MockSOAPServer struct {
Server *httptest.Server
Capture *CameraCapture
}
MockSOAPServer creates a test HTTP server that replays captured SOAP responses
func NewMockSOAPServer ¶
func NewMockSOAPServer(archivePath string) (*MockSOAPServer, error)
NewMockSOAPServer creates a new mock server from a capture archive
func (*MockSOAPServer) URL ¶
func (m *MockSOAPServer) URL() string
URL returns the mock server's URL
Click to show internal directories.
Click to hide internal directories.