Documentation ¶
Overview ¶
Package daptest provides a sample client with utilities for DAP mode testing.
Index ¶
- type Client
- func (c *Client) Close()
- func (c *Client) ConfigurationDoneRequest()
- func (c *Client) ContinueRequest(thread int)
- func (c *Client) DisconnectRequest()
- func (c *Client) ExpectConfigurationDoneResponse(t *testing.T) *dap.ConfigurationDoneResponse
- func (c *Client) ExpectContinueResponse(t *testing.T) *dap.ContinueResponse
- func (c *Client) ExpectDisconnectResponse(t *testing.T) *dap.DisconnectResponse
- func (c *Client) ExpectErrorResponse(t *testing.T) *dap.ErrorResponse
- func (c *Client) ExpectInitializeResponse(t *testing.T) *dap.InitializeResponse
- func (c *Client) ExpectInitializedEvent(t *testing.T) *dap.InitializedEvent
- func (c *Client) ExpectLaunchResponse(t *testing.T) *dap.LaunchResponse
- func (c *Client) ExpectSetBreakpointsResponse(t *testing.T) *dap.SetBreakpointsResponse
- func (c *Client) ExpectSetExceptionBreakpointsResponse(t *testing.T) *dap.SetExceptionBreakpointsResponse
- func (c *Client) ExpectStackTraceResponse(t *testing.T) *dap.StackTraceResponse
- func (c *Client) ExpectStoppedEvent(t *testing.T) *dap.StoppedEvent
- func (c *Client) ExpectTerminatedEvent(t *testing.T) *dap.TerminatedEvent
- func (c *Client) ExpectThreadsResponse(t *testing.T) *dap.ThreadsResponse
- func (c *Client) InitializeRequest()
- func (c *Client) KnownEvent()
- func (c *Client) LaunchRequest(mode string, program string, stopOnEntry bool)
- func (c *Client) LaunchRequestWithArgs(arguments map[string]interface{})
- func (c *Client) ReadMessage() (dap.Message, error)
- func (c *Client) SetBreakpointsRequest(file string, lines []int)
- func (c *Client) SetExceptionBreakpointsRequest()
- func (c *Client) StackTraceRequest()
- func (c *Client) ThreadsRequest()
- func (c *Client) UnknownEvent()
- func (c *Client) UnknownRequest()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a debugger service client that uses Debug Adaptor Protocol. It does not (yet?) implement service.Client interface. All client methods are synchronous.
func NewClient ¶
NewClient creates a new Client over a TCP connection. Call Close() to close the connection.
func (*Client) ConfigurationDoneRequest ¶
func (c *Client) ConfigurationDoneRequest()
ConfigurationDoneRequest sends a 'configurationDone' request.
func (*Client) ContinueRequest ¶
ContinueRequest sends a 'continue' request.
func (*Client) DisconnectRequest ¶
func (c *Client) DisconnectRequest()
DisconnectRequest sends a 'disconnect' request.
func (*Client) ExpectConfigurationDoneResponse ¶
func (*Client) ExpectContinueResponse ¶
func (*Client) ExpectDisconnectResponse ¶
func (*Client) ExpectErrorResponse ¶
func (*Client) ExpectInitializeResponse ¶
func (*Client) ExpectInitializedEvent ¶
func (*Client) ExpectLaunchResponse ¶
func (*Client) ExpectSetBreakpointsResponse ¶
func (*Client) ExpectSetExceptionBreakpointsResponse ¶
func (*Client) ExpectStackTraceResponse ¶
func (*Client) ExpectStoppedEvent ¶
func (*Client) ExpectTerminatedEvent ¶
func (*Client) ExpectThreadsResponse ¶
func (*Client) InitializeRequest ¶
func (c *Client) InitializeRequest()
InitializeRequest sends an 'initialize' request.
func (*Client) KnownEvent ¶
func (c *Client) KnownEvent()
KnownEvent passes decode checks, but delve has no 'case' to handle it. This behaves the same way a new request type added to go-dap, but not to delve.
func (*Client) LaunchRequest ¶
LaunchRequest sends a 'launch' request with the specified args.
func (*Client) LaunchRequestWithArgs ¶
LaunchRequestWithArgs takes a map of untyped implementation-specific arguments to send a 'launch' request. This version can be used to test for values of unexpected types or unspecified values.
func (*Client) ReadMessage ¶
func (*Client) SetBreakpointsRequest ¶
SetBreakpointsRequest sends a 'setBreakpoints' request.
func (*Client) SetExceptionBreakpointsRequest ¶
func (c *Client) SetExceptionBreakpointsRequest()
SetExceptionBreakpointsRequest sends a 'setExceptionBreakpoints' request.
func (*Client) StackTraceRequest ¶
func (c *Client) StackTraceRequest()
StackTraceRequest sends a 'stackTrace' request.
func (*Client) ThreadsRequest ¶
func (c *Client) ThreadsRequest()
ThreadsRequest sends a 'threads' request.
func (*Client) UnknownEvent ¶
func (c *Client) UnknownEvent()
UnknownEvent triggers dap.DecodeProtocolMessageFieldError.
func (*Client) UnknownRequest ¶
func (c *Client) UnknownRequest()
UnknownRequest triggers dap.DecodeProtocolMessageFieldError.