Documentation ¶
Overview ¶
Package tailnettest is a generated GoMock package.
Package tailnettest is a generated GoMock package.
Package tailnettest is a generated GoMock package.
Package tailnettest is a generated GoMock package.
Index ¶
- func DERPIsEmbedded(cfg *derpAndSTUNCfg)
- func DisableSTUN(cfg *derpAndSTUNCfg)
- func RunDERPAndSTUN(t *testing.T, opts ...DERPAndStunOption) (*tailcfg.DERPMap, *derp.Server)
- func RunDERPOnlyWebSockets(t *testing.T) *tailcfg.DERPMap
- type DERPAndStunOption
- type FakeCoordinate
- type FakeCoordinator
- func (*FakeCoordinator) Close() error
- func (f *FakeCoordinator) Coordinate(ctx context.Context, id uuid.UUID, name string, a tailnet.CoordinateeAuth) (chan<- *proto.CoordinateRequest, <-chan *proto.CoordinateResponse)
- func (*FakeCoordinator) Node(uuid.UUID) *tailnet.Node
- func (*FakeCoordinator) ServeHTTPDebug(http.ResponseWriter, *http.Request)
- type FakeServeClient
- type MockCoordinatee
- func (m *MockCoordinatee) EXPECT() *MockCoordinateeMockRecorder
- func (m *MockCoordinatee) SetAllPeersLost()
- func (m *MockCoordinatee) SetNodeCallback(arg0 func(*tailnet.Node))
- func (m *MockCoordinatee) SetTunnelDestination(arg0 uuid.UUID)
- func (m *MockCoordinatee) UpdatePeers(arg0 []*proto.CoordinateResponse_PeerUpdate) error
- type MockCoordinateeMockRecorder
- func (mr *MockCoordinateeMockRecorder) SetAllPeersLost() *gomock.Call
- func (mr *MockCoordinateeMockRecorder) SetNodeCallback(arg0 any) *gomock.Call
- func (mr *MockCoordinateeMockRecorder) SetTunnelDestination(arg0 any) *gomock.Call
- func (mr *MockCoordinateeMockRecorder) UpdatePeers(arg0 any) *gomock.Call
- type MockCoordinator
- func (m *MockCoordinator) Close() error
- func (m *MockCoordinator) Coordinate(arg0 context.Context, arg1 uuid.UUID, arg2 string, ...) (chan<- *proto.CoordinateRequest, <-chan *proto.CoordinateResponse)
- func (m *MockCoordinator) EXPECT() *MockCoordinatorMockRecorder
- func (m *MockCoordinator) Node(arg0 uuid.UUID) *tailnet.Node
- func (m *MockCoordinator) ServeHTTPDebug(arg0 http.ResponseWriter, arg1 *http.Request)
- type MockCoordinatorMockRecorder
- func (mr *MockCoordinatorMockRecorder) Close() *gomock.Call
- func (mr *MockCoordinatorMockRecorder) Coordinate(arg0, arg1, arg2, arg3 any) *gomock.Call
- func (mr *MockCoordinatorMockRecorder) Node(arg0 any) *gomock.Call
- func (mr *MockCoordinatorMockRecorder) ServeHTTPDebug(arg0, arg1 any) *gomock.Call
- type MockSubscription
- type MockSubscriptionMockRecorder
- type MockWorkspaceUpdatesProvider
- type MockWorkspaceUpdatesProviderMockRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DERPIsEmbedded ¶ added in v2.9.0
func DERPIsEmbedded(cfg *derpAndSTUNCfg)
func DisableSTUN ¶ added in v2.9.0
func DisableSTUN(cfg *derpAndSTUNCfg)
func RunDERPAndSTUN ¶
RunDERPAndSTUN creates a DERP mapping for tests.
Types ¶
type DERPAndStunOption ¶ added in v2.9.0
type DERPAndStunOption func(cfg *derpAndSTUNCfg)
type FakeCoordinate ¶ added in v2.8.0
type FakeCoordinate struct { Ctx context.Context ID uuid.UUID Name string Auth tailnet.CoordinateeAuth Reqs chan *proto.CoordinateRequest Resps chan *proto.CoordinateResponse }
type FakeCoordinator ¶ added in v2.8.0
type FakeCoordinator struct {
CoordinateCalls chan *FakeCoordinate
}
func NewFakeCoordinator ¶ added in v2.8.0
func NewFakeCoordinator() *FakeCoordinator
func (*FakeCoordinator) Close ¶ added in v2.8.0
func (*FakeCoordinator) Close() error
func (*FakeCoordinator) Coordinate ¶ added in v2.8.0
func (f *FakeCoordinator) Coordinate(ctx context.Context, id uuid.UUID, name string, a tailnet.CoordinateeAuth) (chan<- *proto.CoordinateRequest, <-chan *proto.CoordinateResponse)
func (*FakeCoordinator) Node ¶ added in v2.8.0
func (*FakeCoordinator) Node(uuid.UUID) *tailnet.Node
func (*FakeCoordinator) ServeHTTPDebug ¶ added in v2.8.0
func (*FakeCoordinator) ServeHTTPDebug(http.ResponseWriter, *http.Request)
type FakeServeClient ¶ added in v2.8.0
type MockCoordinatee ¶ added in v2.8.0
type MockCoordinatee struct {
// contains filtered or unexported fields
}
MockCoordinatee is a mock of Coordinatee interface.
func NewMockCoordinatee ¶ added in v2.8.0
func NewMockCoordinatee(ctrl *gomock.Controller) *MockCoordinatee
NewMockCoordinatee creates a new mock instance.
func (*MockCoordinatee) EXPECT ¶ added in v2.8.0
func (m *MockCoordinatee) EXPECT() *MockCoordinateeMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockCoordinatee) SetAllPeersLost ¶ added in v2.8.0
func (m *MockCoordinatee) SetAllPeersLost()
SetAllPeersLost mocks base method.
func (*MockCoordinatee) SetNodeCallback ¶ added in v2.8.0
func (m *MockCoordinatee) SetNodeCallback(arg0 func(*tailnet.Node))
SetNodeCallback mocks base method.
func (*MockCoordinatee) SetTunnelDestination ¶ added in v2.11.0
func (m *MockCoordinatee) SetTunnelDestination(arg0 uuid.UUID)
SetTunnelDestination mocks base method.
func (*MockCoordinatee) UpdatePeers ¶ added in v2.8.0
func (m *MockCoordinatee) UpdatePeers(arg0 []*proto.CoordinateResponse_PeerUpdate) error
UpdatePeers mocks base method.
type MockCoordinateeMockRecorder ¶ added in v2.8.0
type MockCoordinateeMockRecorder struct {
// contains filtered or unexported fields
}
MockCoordinateeMockRecorder is the mock recorder for MockCoordinatee.
func (*MockCoordinateeMockRecorder) SetAllPeersLost ¶ added in v2.8.0
func (mr *MockCoordinateeMockRecorder) SetAllPeersLost() *gomock.Call
SetAllPeersLost indicates an expected call of SetAllPeersLost.
func (*MockCoordinateeMockRecorder) SetNodeCallback ¶ added in v2.8.0
func (mr *MockCoordinateeMockRecorder) SetNodeCallback(arg0 any) *gomock.Call
SetNodeCallback indicates an expected call of SetNodeCallback.
func (*MockCoordinateeMockRecorder) SetTunnelDestination ¶ added in v2.11.0
func (mr *MockCoordinateeMockRecorder) SetTunnelDestination(arg0 any) *gomock.Call
SetTunnelDestination indicates an expected call of SetTunnelDestination.
func (*MockCoordinateeMockRecorder) UpdatePeers ¶ added in v2.8.0
func (mr *MockCoordinateeMockRecorder) UpdatePeers(arg0 any) *gomock.Call
UpdatePeers indicates an expected call of UpdatePeers.
type MockCoordinator ¶ added in v2.7.1
type MockCoordinator struct {
// contains filtered or unexported fields
}
MockCoordinator is a mock of Coordinator interface.
func NewMockCoordinator ¶ added in v2.7.1
func NewMockCoordinator(ctrl *gomock.Controller) *MockCoordinator
NewMockCoordinator creates a new mock instance.
func (*MockCoordinator) Close ¶ added in v2.7.1
func (m *MockCoordinator) Close() error
Close mocks base method.
func (*MockCoordinator) Coordinate ¶ added in v2.7.1
func (m *MockCoordinator) Coordinate(arg0 context.Context, arg1 uuid.UUID, arg2 string, arg3 tailnet.CoordinateeAuth) (chan<- *proto.CoordinateRequest, <-chan *proto.CoordinateResponse)
Coordinate mocks base method.
func (*MockCoordinator) EXPECT ¶ added in v2.7.1
func (m *MockCoordinator) EXPECT() *MockCoordinatorMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockCoordinator) Node ¶ added in v2.7.1
func (m *MockCoordinator) Node(arg0 uuid.UUID) *tailnet.Node
Node mocks base method.
func (*MockCoordinator) ServeHTTPDebug ¶ added in v2.7.1
func (m *MockCoordinator) ServeHTTPDebug(arg0 http.ResponseWriter, arg1 *http.Request)
ServeHTTPDebug mocks base method.
type MockCoordinatorMockRecorder ¶ added in v2.7.1
type MockCoordinatorMockRecorder struct {
// contains filtered or unexported fields
}
MockCoordinatorMockRecorder is the mock recorder for MockCoordinator.
func (*MockCoordinatorMockRecorder) Close ¶ added in v2.7.1
func (mr *MockCoordinatorMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close.
func (*MockCoordinatorMockRecorder) Coordinate ¶ added in v2.7.1
func (mr *MockCoordinatorMockRecorder) Coordinate(arg0, arg1, arg2, arg3 any) *gomock.Call
Coordinate indicates an expected call of Coordinate.
func (*MockCoordinatorMockRecorder) Node ¶ added in v2.7.1
func (mr *MockCoordinatorMockRecorder) Node(arg0 any) *gomock.Call
Node indicates an expected call of Node.
func (*MockCoordinatorMockRecorder) ServeHTTPDebug ¶ added in v2.7.1
func (mr *MockCoordinatorMockRecorder) ServeHTTPDebug(arg0, arg1 any) *gomock.Call
ServeHTTPDebug indicates an expected call of ServeHTTPDebug.
type MockSubscription ¶ added in v2.18.0
type MockSubscription struct {
// contains filtered or unexported fields
}
MockSubscription is a mock of Subscription interface.
func NewMockSubscription ¶ added in v2.18.0
func NewMockSubscription(ctrl *gomock.Controller) *MockSubscription
NewMockSubscription creates a new mock instance.
func (*MockSubscription) Close ¶ added in v2.18.0
func (m *MockSubscription) Close() error
Close mocks base method.
func (*MockSubscription) EXPECT ¶ added in v2.18.0
func (m *MockSubscription) EXPECT() *MockSubscriptionMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockSubscription) Updates ¶ added in v2.18.0
func (m *MockSubscription) Updates() <-chan *proto.WorkspaceUpdate
Updates mocks base method.
type MockSubscriptionMockRecorder ¶ added in v2.18.0
type MockSubscriptionMockRecorder struct {
// contains filtered or unexported fields
}
MockSubscriptionMockRecorder is the mock recorder for MockSubscription.
func (*MockSubscriptionMockRecorder) Close ¶ added in v2.18.0
func (mr *MockSubscriptionMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close.
func (*MockSubscriptionMockRecorder) Updates ¶ added in v2.18.0
func (mr *MockSubscriptionMockRecorder) Updates() *gomock.Call
Updates indicates an expected call of Updates.
type MockWorkspaceUpdatesProvider ¶ added in v2.18.0
type MockWorkspaceUpdatesProvider struct {
// contains filtered or unexported fields
}
MockWorkspaceUpdatesProvider is a mock of WorkspaceUpdatesProvider interface.
func NewMockWorkspaceUpdatesProvider ¶ added in v2.18.0
func NewMockWorkspaceUpdatesProvider(ctrl *gomock.Controller) *MockWorkspaceUpdatesProvider
NewMockWorkspaceUpdatesProvider creates a new mock instance.
func (*MockWorkspaceUpdatesProvider) Close ¶ added in v2.18.0
func (m *MockWorkspaceUpdatesProvider) Close() error
Close mocks base method.
func (*MockWorkspaceUpdatesProvider) EXPECT ¶ added in v2.18.0
func (m *MockWorkspaceUpdatesProvider) EXPECT() *MockWorkspaceUpdatesProviderMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockWorkspaceUpdatesProvider) Subscribe ¶ added in v2.18.0
func (m *MockWorkspaceUpdatesProvider) Subscribe(arg0 context.Context, arg1 uuid.UUID) (tailnet.Subscription, error)
Subscribe mocks base method.
type MockWorkspaceUpdatesProviderMockRecorder ¶ added in v2.18.0
type MockWorkspaceUpdatesProviderMockRecorder struct {
// contains filtered or unexported fields
}
MockWorkspaceUpdatesProviderMockRecorder is the mock recorder for MockWorkspaceUpdatesProvider.
func (*MockWorkspaceUpdatesProviderMockRecorder) Close ¶ added in v2.18.0
func (mr *MockWorkspaceUpdatesProviderMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close.