2022-07-24 16:51:42 -04:00
|
|
|
package rest
|
|
|
|
|
|
|
|
import (
|
|
|
|
"context"
|
|
|
|
"testing"
|
|
|
|
|
|
|
|
"github.com/stretchr/testify/require"
|
2022-11-09 15:53:01 -04:00
|
|
|
"github.com/waku-org/go-waku/waku/v2/node"
|
|
|
|
"github.com/waku-org/go-waku/waku/v2/utils"
|
2022-07-24 16:51:42 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
func TestWakuRest(t *testing.T) {
|
|
|
|
options := node.WithWakuStore(false, false)
|
|
|
|
n, err := node.New(context.Background(), options)
|
|
|
|
require.NoError(t, err)
|
|
|
|
|
|
|
|
rpc := NewWakuRest(n, "127.0.0.1", 8080, true, true, 10, utils.Logger())
|
|
|
|
require.NotNil(t, rpc.server)
|
|
|
|
require.Equal(t, rpc.server.Addr, "127.0.0.1:8080")
|
|
|
|
}
|