Skip to content

Commit ea6b523

Browse files
committed
pss: lint
1 parent c174ac1 commit ea6b523

File tree

6 files changed

+6
-23
lines changed

6 files changed

+6
-23
lines changed

pss/outbox/message.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
package outbox
22

33
import (
4-
"github.com/ethersphere/swarm/pss/message"
54
"time"
5+
6+
"github.com/ethersphere/swarm/pss/message"
67
)
78

89
type outboxMsg struct {

pss/outbox/outbox.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package outbox
22

33
import (
44
"errors"
5+
56
"github.com/ethereum/go-ethereum/metrics"
67
"github.com/ethersphere/swarm/log"
78
"github.com/ethersphere/swarm/pss/message"

pss/outbox/outbox_test.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,13 @@ package outbox_test
22

33
import (
44
"errors"
5-
"github.com/ethersphere/swarm/pss/outbox"
65
"testing"
7-
"time"
86

97
"github.com/epiclabs-io/ut"
108
"github.com/ethersphere/swarm/pss/message"
9+
"github.com/ethersphere/swarm/pss/outbox"
1110
)
1211

13-
const waitTimeout = 2 * time.Second
14-
1512
func TestOutbox(tx *testing.T) {
1613
t := ut.BeginTest(tx, false)
1714
defer t.FinishTest()

pss/outbox/outbox_whitebox_test.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
package outbox
22

33
import (
4+
"testing"
5+
46
"github.com/epiclabs-io/ut"
57
"github.com/ethersphere/swarm/pss/message"
6-
"testing"
7-
"time"
88
)
99

10-
const waitTimeout = 2 * time.Second
11-
1210
func TestFullOutbox(tx *testing.T) {
1311
t := ut.BeginTest(tx, false)
1412
defer t.FinishTest()

pss/pss_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ import (
2222
"crypto/ecdsa"
2323
"encoding/binary"
2424
"encoding/hex"
25-
"errors"
2625
"fmt"
2726
"math/rand"
2827
"strconv"

pss/types.go

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ package pss
1818

1919
import (
2020
"encoding/json"
21-
"time"
2221

2322
"github.com/ethereum/go-ethereum/common/hexutil"
2423
"github.com/ethereum/go-ethereum/p2p"
@@ -49,18 +48,6 @@ func (a *PssAddress) UnmarshalJSON(input []byte) error {
4948
return nil
5049
}
5150

52-
type outboxMsg struct {
53-
msg *message.Message
54-
startedAt time.Time
55-
}
56-
57-
func newOutboxMsg(msg *message.Message) *outboxMsg {
58-
return &outboxMsg{
59-
msg: msg,
60-
startedAt: time.Now(),
61-
}
62-
}
63-
6451
// Signature for a message handler function for a Message
6552
// Implementations of this type are passed to Pss.Register together with a topic,
6653
type HandlerFunc func(msg []byte, p *p2p.Peer, asymmetric bool, keyid string) error

0 commit comments

Comments
 (0)