mirror of
https://github.com/logos-messaging/logos-messaging-go.git
synced 2026-08-25 00:01:19 +00:00
test: build example in jenkins
Add command for generating coverage
This commit is contained in:
@@ -40,7 +40,7 @@ func main() {
|
||||
|
||||
wakuNode, err := node.New(ctx,
|
||||
node.WithPrivateKey(prvKey),
|
||||
node.WithHostAddress([]net.Addr{hostAddr}),
|
||||
node.WithHostAddress([]*net.TCPAddr{hostAddr}),
|
||||
node.WithWakuRelay(),
|
||||
)
|
||||
if err != nil {
|
||||
@@ -93,7 +93,7 @@ func write(ctx context.Context, wakuNode *node.WakuNode, msgContent string) {
|
||||
Timestamp: timestamp,
|
||||
}
|
||||
|
||||
_, err = wakuNode.Publish(ctx, msg, nil)
|
||||
_, err = wakuNode.Relay().Publish(ctx, msg, nil)
|
||||
if err != nil {
|
||||
log.Error("Error sending a message: ", err)
|
||||
}
|
||||
@@ -107,7 +107,7 @@ func writeLoop(ctx context.Context, wakuNode *node.WakuNode) {
|
||||
}
|
||||
|
||||
func readLoop(ctx context.Context, wakuNode *node.WakuNode) {
|
||||
sub, err := wakuNode.Subscribe(ctx, nil)
|
||||
sub, err := wakuNode.Relay().Subscribe(ctx, nil)
|
||||
if err != nil {
|
||||
log.Error("Could not subscribe: ", err)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user