parent
8ce6efc749
commit
d5be8c525d
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"Exclude": [
|
||||
".*_mock.go",
|
||||
"geth/jail/doc.go",
|
||||
"jail/doc.go",
|
||||
".*Errors unhandled.*fmt.Fprint.*gasv2.*"
|
||||
],
|
||||
"Skip": ["helpers", "static"],
|
||||
|
|
10
Makefile
10
Makefile
|
@ -13,7 +13,7 @@ CGO_CFLAGS=-I/$(JAVA_HOME)/include -I/$(JAVA_HOME)/include/darwin
|
|||
GOBIN=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))build/bin
|
||||
GIT_COMMIT := $(shell git rev-parse --short HEAD)
|
||||
|
||||
BUILD_FLAGS ?= $(shell echo "-ldflags '-X main.buildStamp=`date -u '+%Y-%m-%d.%H:%M:%S'` -X github.com/status-im/status-go/geth/params.VersionMeta=$(GIT_COMMIT)'")
|
||||
BUILD_FLAGS ?= $(shell echo "-ldflags '-X main.buildStamp=`date -u '+%Y-%m-%d.%H:%M:%S'` -X github.com/status-im/status-go/params.VersionMeta=$(GIT_COMMIT)'")
|
||||
|
||||
GO ?= latest
|
||||
XGOVERSION ?= 1.10.x
|
||||
|
@ -130,10 +130,10 @@ mock-install: ##@other Install mocking tools
|
|||
go get -u github.com/golang/mock/mockgen
|
||||
|
||||
mock: ##@other Regenerate mocks
|
||||
mockgen -package=fcm -destination=geth/notifications/push/fcm/client_mock.go -source=geth/notifications/push/fcm/client.go
|
||||
mockgen -package=fake -destination=geth/transactions/fake/mock.go -source=geth/transactions/fake/txservice.go
|
||||
mockgen -package=account -destination=geth/account/accounts_mock.go -source=geth/account/accounts.go
|
||||
mockgen -package=jail -destination=geth/jail/cell_mock.go -source=geth/jail/cell.go
|
||||
mockgen -package=fcm -destination=notifications/push/fcm/client_mock.go -source=notifications/push/fcm/client.go
|
||||
mockgen -package=fake -destination=transactions/fake/mock.go -source=transactions/fake/txservice.go
|
||||
mockgen -package=account -destination=account/accounts_mock.go -source=account/accounts.go
|
||||
mockgen -package=jail -destination=jail/cell_mock.go -source=jail/cell.go
|
||||
mockgen -package=status -destination=services/status/account_mock.go -source=services/status/service.go
|
||||
|
||||
docker-test: ##@tests Run tests in a docker container with golang.
|
||||
|
|
|
@ -85,7 +85,7 @@ If you have problems running tests on public network we suggest reading [e2e gui
|
|||
If you want to launch specific test, for instance `RPCSendTransactions`, use the following command:
|
||||
|
||||
```shell
|
||||
go test -v ./geth/api/ -testify.m ^RPCSendTransaction$
|
||||
go test -v ./api/ -testify.m ^RPCSendTransaction$
|
||||
```
|
||||
|
||||
Note `-testify.m` as [testify/suite](https://godoc.org/github.com/stretchr/testify/suite) is used to group individual tests.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// Code generated by MockGen. DO NOT EDIT.
|
||||
// Source: geth/account/accounts.go
|
||||
// Source: account/accounts.go
|
||||
|
||||
// Package account is a generated GoMock package.
|
||||
package account
|
|
@ -7,12 +7,12 @@ import (
|
|||
"github.com/ethereum/go-ethereum/accounts/keystore"
|
||||
gethcommon "github.com/ethereum/go-ethereum/common"
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/status-im/status-go/geth/account"
|
||||
"github.com/status-im/status-go/geth/jail"
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/geth/transactions"
|
||||
"github.com/status-im/status-go/account"
|
||||
"github.com/status-im/status-go/jail"
|
||||
"github.com/status-im/status-go/node"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/sign"
|
||||
"github.com/status-im/status-go/transactions"
|
||||
)
|
||||
|
||||
// StatusAPI provides API to access Status related functionality.
|
||||
|
@ -31,7 +31,7 @@ func NewStatusAPI() *StatusAPI {
|
|||
func NewStatusAPIWithBackend(b *StatusBackend) *StatusAPI {
|
||||
return &StatusAPI{
|
||||
b: b,
|
||||
log: log.New("package", "status-go/geth/api.StatusAPI"),
|
||||
log: log.New("package", "status-go/api.StatusAPI"),
|
||||
}
|
||||
}
|
||||
|
|
@ -12,17 +12,17 @@ import (
|
|||
|
||||
fcmlib "github.com/NaySoftware/go-fcm"
|
||||
|
||||
"github.com/status-im/status-go/geth/account"
|
||||
"github.com/status-im/status-go/geth/jail"
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/geth/notifications/push/fcm"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/geth/rpc"
|
||||
"github.com/status-im/status-go/geth/transactions"
|
||||
"github.com/status-im/status-go/account"
|
||||
"github.com/status-im/status-go/jail"
|
||||
"github.com/status-im/status-go/node"
|
||||
"github.com/status-im/status-go/notifications/push/fcm"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/rpc"
|
||||
"github.com/status-im/status-go/services/personal"
|
||||
"github.com/status-im/status-go/services/rpcfilters"
|
||||
"github.com/status-im/status-go/sign"
|
||||
"github.com/status-im/status-go/signal"
|
||||
"github.com/status-im/status-go/transactions"
|
||||
)
|
||||
|
||||
const (
|
||||
|
@ -71,7 +71,7 @@ func NewStatusBackend() *StatusBackend {
|
|||
transactor: transactor,
|
||||
personalAPI: personalAPI,
|
||||
newNotification: notificationManager,
|
||||
log: log.New("package", "status-go/geth/api.StatusBackend"),
|
||||
log: log.New("package", "status-go/api.StatusBackend"),
|
||||
}
|
||||
}
|
||||
|
|
@ -8,8 +8,8 @@ import (
|
|||
"testing"
|
||||
|
||||
"github.com/ethereum/go-ethereum/common/hexutil"
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/node"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
|
@ -9,8 +9,8 @@ import (
|
|||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/status-im/status-go/geth/api"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/api"
|
||||
"github.com/status-im/status-go/params"
|
||||
)
|
||||
|
||||
// command contains the result of a parsed command line and
|
||||
|
|
|
@ -7,7 +7,7 @@ import (
|
|||
"reflect"
|
||||
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/status-im/status-go/geth/api"
|
||||
"github.com/status-im/status-go/api"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -11,9 +11,9 @@ import (
|
|||
"sync"
|
||||
"testing"
|
||||
|
||||
"github.com/status-im/status-go/api"
|
||||
"github.com/status-im/status-go/cmd/statusd/debug"
|
||||
"github.com/status-im/status-go/geth/api"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ import (
|
|||
"fmt"
|
||||
"testing"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
|
|
|
@ -15,12 +15,12 @@ import (
|
|||
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/ethereum/go-ethereum/p2p/discv5"
|
||||
"github.com/status-im/status-go/api"
|
||||
"github.com/status-im/status-go/cmd/statusd/debug"
|
||||
"github.com/status-im/status-go/cmd/statusd/topics"
|
||||
"github.com/status-im/status-go/geth/api"
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
nodemetrics "github.com/status-im/status-go/metrics/node"
|
||||
"github.com/status-im/status-go/node"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/profiling"
|
||||
)
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ import (
|
|||
"context"
|
||||
"time"
|
||||
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/node"
|
||||
)
|
||||
|
||||
func createContextFromTimeout(timeout int) (context.Context, context.CancelFunc) {
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/ethereum/go-ethereum/p2p/discv5"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
)
|
||||
|
||||
// TopicFlag used to parse discv5 topics.
|
||||
|
|
|
@ -3,7 +3,7 @@ package topics
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"fmt"
|
||||
"io/ioutil"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
)
|
||||
|
||||
// whisperConfig creates node configuration object from flags
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
# jail [![GoDoc](https://godoc.org/github.com/status-im/status-go/geth/jail?status.png)](https://godoc.org/github.com/status-im/status-go/geth/jail)
|
||||
# jail [![GoDoc](https://godoc.org/github.com/status-im/status-go/jail?status.png)](https://godoc.org/github.com/status-im/status-go/jail)
|
||||
jail - jailed environment for executing JS code.
|
||||
|
||||
Download:
|
||||
```shell
|
||||
go get github.com/status-im/status-go/geth/jail
|
||||
go get github.com/status-im/status-go/jail
|
||||
```
|
||||
|
||||
* * *
|
||||
|
@ -47,7 +47,7 @@ wrappers around Otto VM functions of the same name. `Run` accepts raw JS strings
|
|||
Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions,
|
||||
because they're not part of ECMA-262 spec, but properties of the window object in browser.
|
||||
|
||||
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/geth/jail/internal).
|
||||
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/jail/internal).
|
||||
|
||||
Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop.
|
||||
|
|
@ -6,11 +6,11 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/jail/internal/fetch"
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop/looptask"
|
||||
"github.com/status-im/status-go/geth/jail/internal/timers"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/fetch"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/loop/looptask"
|
||||
"github.com/status-im/status-go/jail/internal/timers"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
const timeout = 5 * time.Second
|
|
@ -1,5 +1,5 @@
|
|||
// Code generated by MockGen. DO NOT EDIT.
|
||||
// Source: geth/jail/cell.go
|
||||
// Source: jail/cell.go
|
||||
|
||||
// Package jail is a generated GoMock package.
|
||||
package jail
|
|
@ -8,7 +8,7 @@ import (
|
|||
"testing"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/jail/console"
|
||||
"github.com/status-im/status-go/jail/console"
|
||||
"github.com/status-im/status-go/signal"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
jail - jailed environment for executing JS code.
|
||||
Package jail - jailed environment for executing JS code.
|
||||
|
||||
Package jail implements "jailed" environment for executing arbitrary
|
||||
JavaScript code using Otto JS interpreter (https://github.com/robertkrimen/otto).
|
||||
|
@ -37,7 +37,7 @@ wrappers around Otto VM functions of the same name. `Run` accepts raw JS strings
|
|||
Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions,
|
||||
because they're not part of ECMA-262 spec, but properties of the window object in browser.
|
||||
|
||||
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/geth/jail/internal).
|
||||
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/jail/internal).
|
||||
|
||||
Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop.
|
||||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"os"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/jail/console"
|
||||
"github.com/status-im/status-go/jail/console"
|
||||
"github.com/status-im/status-go/signal"
|
||||
)
|
||||
|
|
@ -12,8 +12,8 @@ import (
|
|||
"sync/atomic"
|
||||
|
||||
gethrpc "github.com/ethereum/go-ethereum/rpc"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/geth/rpc"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/rpc"
|
||||
"github.com/status-im/status-go/signal"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
|
@ -3,7 +3,7 @@ ottoext
|
|||
|
||||
Originally based on [github.com/deoxxa/ottoext](https://github.com/deoxxa/ottoext)
|
||||
|
||||
[![GoDoc](https://godoc.org/github.com/status-im/status-go/geth/jail/ottoext?status.svg)](https://godoc.org/github.com/status-im/status-go/geth/jail/ottoext)
|
||||
[![GoDoc](https://godoc.org/github.com/status-im/status-go/jail/ottoext?status.svg)](https://godoc.org/github.com/status-im/status-go/jail/ottoext)
|
||||
|
||||
Overview
|
||||
--------
|
|
@ -11,9 +11,9 @@ import (
|
|||
|
||||
"github.com/robertkrimen/otto"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/promise"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/promise"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
func mustValue(v otto.Value, err error) otto.Value {
|
|
@ -9,9 +9,9 @@ import (
|
|||
|
||||
"github.com/robertkrimen/otto"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/fetch"
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/fetch"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
||||
|
|
@ -6,7 +6,7 @@ import (
|
|||
"sync"
|
||||
"sync/atomic"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
// ErrClosed represents the error returned when we try to add or ready
|
|
@ -6,7 +6,7 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
||||
|
|
@ -4,8 +4,8 @@ import (
|
|||
"errors"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
// IdleTask is designed to sit in a loop and keep it active, without doing any
|
|
@ -1,9 +1,9 @@
|
|||
package promise
|
||||
|
||||
import (
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/timers"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/timers"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
//Define jail promise
|
|
@ -7,9 +7,9 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/suite"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/promise"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/promise"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
func (s *PromiseSuite) TestResolve() {
|
|
@ -4,8 +4,8 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
type timerTask struct {
|
|
@ -5,8 +5,8 @@ import (
|
|||
|
||||
"github.com/robertkrimen/otto"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
)
|
||||
|
||||
// Define jail timers
|
|
@ -5,9 +5,9 @@ import (
|
|||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/status-im/status-go/geth/jail/internal/loop"
|
||||
"github.com/status-im/status-go/geth/jail/internal/timers"
|
||||
"github.com/status-im/status-go/geth/jail/internal/vm"
|
||||
"github.com/status-im/status-go/jail/internal/loop"
|
||||
"github.com/status-im/status-go/jail/internal/timers"
|
||||
"github.com/status-im/status-go/jail/internal/vm"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
||||
|
|
@ -9,7 +9,7 @@ import (
|
|||
|
||||
"github.com/robertkrimen/otto"
|
||||
web3js "github.com/status-im/go-web3js"
|
||||
"github.com/status-im/status-go/geth/rpc"
|
||||
"github.com/status-im/status-go/rpc"
|
||||
)
|
||||
|
||||
const (
|
|
@ -5,7 +5,7 @@ import (
|
|||
"testing"
|
||||
|
||||
"github.com/robertkrimen/otto"
|
||||
"github.com/status-im/status-go/geth/rpc"
|
||||
"github.com/status-im/status-go/rpc"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
||||
|
|
@ -8,8 +8,8 @@ import (
|
|||
|
||||
"github.com/NaySoftware/go-fcm"
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/logutils"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/profiling"
|
||||
"github.com/status-im/status-go/sign"
|
||||
"gopkg.in/go-playground/validator.v9"
|
||||
|
|
|
@ -31,13 +31,13 @@ import (
|
|||
gethparams "github.com/ethereum/go-ethereum/params"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/status-im/status-go/geth/account"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/geth/transactions"
|
||||
"github.com/status-im/status-go/account"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/sign"
|
||||
"github.com/status-im/status-go/signal"
|
||||
"github.com/status-im/status-go/static"
|
||||
. "github.com/status-im/status-go/t/utils" //nolint: golint
|
||||
"github.com/status-im/status-go/transactions"
|
||||
)
|
||||
|
||||
const initJS = `
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package main
|
||||
|
||||
import "github.com/status-im/status-go/geth/api"
|
||||
import "github.com/status-im/status-go/api"
|
||||
|
||||
var statusAPI = api.NewStatusAPI()
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/metrics"
|
||||
"github.com/ethereum/go-ethereum/rlp"
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/syndtr/goleveldb/leveldb"
|
||||
"github.com/syndtr/goleveldb/leveldb/util"
|
||||
)
|
||||
|
|
|
@ -29,7 +29,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/crypto"
|
||||
"github.com/ethereum/go-ethereum/rlp"
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/suite"
|
||||
)
|
||||
|
||||
|
|
|
@ -20,9 +20,9 @@ import (
|
|||
"github.com/ethereum/go-ethereum/p2p/discv5"
|
||||
"github.com/ethereum/go-ethereum/p2p/nat"
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/mailserver"
|
||||
shhmetrics "github.com/status-im/status-go/metrics/whisper"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/services/personal"
|
||||
"github.com/status-im/status-go/services/shhext"
|
||||
"github.com/status-im/status-go/services/status"
|
||||
|
@ -40,7 +40,7 @@ var (
|
|||
)
|
||||
|
||||
// All general log messages in this package should be routed through this logger.
|
||||
var logger = log.New("package", "status-go/geth/node")
|
||||
var logger = log.New("package", "status-go/node")
|
||||
|
||||
// MakeNode create a geth node entity
|
||||
func MakeNode(config *params.NodeConfig, db *leveldb.DB) (*node.Node, error) {
|
|
@ -5,7 +5,7 @@ import (
|
|||
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
@ -18,10 +18,10 @@ import (
|
|||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
"github.com/syndtr/goleveldb/leveldb"
|
||||
|
||||
"github.com/status-im/status-go/geth/db"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/geth/peers"
|
||||
"github.com/status-im/status-go/geth/rpc"
|
||||
"github.com/status-im/status-go/db"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/peers"
|
||||
"github.com/status-im/status-go/rpc"
|
||||
"github.com/status-im/status-go/services/status"
|
||||
)
|
||||
|
||||
|
@ -57,7 +57,7 @@ type StatusNode struct {
|
|||
// New makes new instance of StatusNode.
|
||||
func New() *StatusNode {
|
||||
return &StatusNode{
|
||||
log: log.New("package", "status-go/geth/node.StatusNode"),
|
||||
log: log.New("package", "status-go/node.StatusNode"),
|
||||
}
|
||||
}
|
||||
|
|
@ -10,8 +10,8 @@ import (
|
|||
"github.com/ethereum/go-ethereum/p2p"
|
||||
"github.com/ethereum/go-ethereum/rpc"
|
||||
|
||||
"github.com/status-im/status-go/geth/node"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/node"
|
||||
"github.com/status-im/status-go/params"
|
||||
)
|
||||
|
||||
type TestServiceAPI struct{}
|
|
@ -16,7 +16,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/p2p/discover"
|
||||
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
// Code generated by MockGen. DO NOT EDIT.
|
||||
// Source: geth/notifications/push/fcm/client.go
|
||||
// Source: notifications/push/fcm/client.go
|
||||
|
||||
// Package fcm is a generated GoMock package.
|
||||
package fcm
|
|
@ -332,7 +332,7 @@ func NewNodeConfig(dataDir string, clstrCfgFile string, networkID uint64) (*Node
|
|||
MaxPeers: MaxPeers,
|
||||
MaxPendingPeers: MaxPendingPeers,
|
||||
IPCFile: IPCFile,
|
||||
log: log.New("package", "status-go/geth/params.NodeConfig"),
|
||||
log: log.New("package", "status-go/params.NodeConfig"),
|
||||
LogFile: LogFile,
|
||||
LogLevel: LogLevel,
|
||||
LogToStderr: LogToStderr,
|
|
@ -13,7 +13,7 @@ import (
|
|||
|
||||
"github.com/ethereum/go-ethereum/core"
|
||||
gethparams "github.com/ethereum/go-ethereum/params"
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
@ -16,7 +16,7 @@ const (
|
|||
)
|
||||
|
||||
// VersionMeta is metadata to append to the version string
|
||||
var VersionMeta string // rely on linker: -ldflags -X github.com/status-im/status-go/geth/params.VersionMeta"
|
||||
var VersionMeta string // rely on linker: -ldflags -X github.com/status-im/status-go/params.VersionMeta"
|
||||
|
||||
// Version exposes string representation of program version.
|
||||
var Version = fmt.Sprintf("%d.%d.%d-%s", VersionMajor, VersionMinor, VersionPatch, VersionMeta)
|
|
@ -3,7 +3,7 @@ package peers
|
|||
import (
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/ethereum/go-ethereum/p2p/discv5"
|
||||
"github.com/status-im/status-go/geth/db"
|
||||
"github.com/status-im/status-go/db"
|
||||
"github.com/syndtr/goleveldb/leveldb"
|
||||
"github.com/syndtr/goleveldb/leveldb/util"
|
||||
)
|
|
@ -12,7 +12,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/p2p/discover"
|
||||
"github.com/ethereum/go-ethereum/p2p/discv5"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/signal"
|
||||
)
|
||||
|
|
@ -17,7 +17,7 @@ import (
|
|||
"github.com/stretchr/testify/require"
|
||||
"github.com/stretchr/testify/suite"
|
||||
|
||||
"github.com/status-im/status-go/geth/params"
|
||||
"github.com/status-im/status-go/params"
|
||||
"github.com/status-im/status-go/signal"
|
||||
|
||||
// to access logs in the test with `-log` flag
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue