mock

package
v3.22.1 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package mock provides mock implementation of necessary NS interfaces for testing.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NS

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

NS is a mock NS for GS tests.

func StartNS

func StartNS(ctx context.Context) (*NS, string)

StartNS starts the mock NS.

func (ns *NS) HandleUplink(ctx context.Context, msg *ttnpb.UplinkMessage) (*types.Empty, error)

HandleUplink implements ttnpb.GsNsServer

func (*NS) ReportTxAcknowledgment added in v3.12.0

func (ns *NS) ReportTxAcknowledgment(ctx context.Context, msg *ttnpb.GatewayTxAcknowledgment) (*types.Empty, error)

ReportTxAcknowledgment implements ttnpb.GsNsServer

func (*NS) TxAck added in v3.12.0

func (ns *NS) TxAck() <-chan *ttnpb.GatewayTxAcknowledgment

TxAck returns the TxAck channel.

func (*NS) Up

func (ns *NS) Up() <-chan *ttnpb.UplinkMessage

Up returns the upstream channel.

Jump to

Keyboard shortcuts

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