Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neoppod
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Levin Zimmermann
neoppod
Commits
0b18819a
Commit
0b18819a
authored
Apr 28, 2017
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
213b9f14
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
67 additions
and
114 deletions
+67
-114
go/neo/connection.go
go/neo/connection.go
+63
-110
go/neo/connection_test.go
go/neo/connection_test.go
+4
-4
No files found.
go/neo/connection.go
View file @
0b18819a
This diff is collapsed.
Click to expand it.
go/neo/connection_test.go
View file @
0b18819a
...
@@ -363,7 +363,7 @@ func TestNodeLink(t *testing.T) {
...
@@ -363,7 +363,7 @@ func TestNodeLink(t *testing.T) {
// NewConn after NodeLink stop
// NewConn after NodeLink stop
c
,
err
=
nl1
.
NewConn
()
c
,
err
=
nl1
.
NewConn
()
if
err
!=
ErrLink
Stopped
{
if
err
!=
ErrLink
Down
{
t
.
Fatalf
(
"NewConn after NodeLink stop: %v"
,
err
)
t
.
Fatalf
(
"NewConn after NodeLink stop: %v"
,
err
)
}
}
...
@@ -373,17 +373,17 @@ func TestNodeLink(t *testing.T) {
...
@@ -373,17 +373,17 @@ func TestNodeLink(t *testing.T) {
t
.
Fatalf
(
"Conn.Recv 2 after peer NodeLink shutdown: pkt = %v err = %v"
,
pkt
,
err
)
t
.
Fatalf
(
"Conn.Recv 2 after peer NodeLink shutdown: pkt = %v err = %v"
,
pkt
,
err
)
}
}
err
=
c13
.
Send
(
&
PktBuf
{[]
byte
(
"data"
)})
err
=
c13
.
Send
(
&
PktBuf
{[]
byte
(
"data"
)})
if
err
!=
ErrLink
Stopped
{
if
err
!=
ErrLink
Down
{
t
.
Fatalf
(
"Conn.Send 2 after peer NodeLink shutdown: %v"
,
err
)
t
.
Fatalf
(
"Conn.Send 2 after peer NodeLink shutdown: %v"
,
err
)
}
}
// Recv/Send error on second call
// Recv/Send error on second call
pkt
,
err
=
c11
.
Recv
()
pkt
,
err
=
c11
.
Recv
()
if
!
(
pkt
==
nil
&&
err
==
ErrLink
Stopped
)
{
if
!
(
pkt
==
nil
&&
err
==
ErrLink
Down
)
{
t
.
Fatalf
(
"Conn.Recv after NodeLink stop: pkt = %v err = %v"
,
pkt
,
err
)
t
.
Fatalf
(
"Conn.Recv after NodeLink stop: pkt = %v err = %v"
,
pkt
,
err
)
}
}
err
=
c12
.
Send
(
&
PktBuf
{[]
byte
(
"data"
)})
err
=
c12
.
Send
(
&
PktBuf
{[]
byte
(
"data"
)})
if
err
!=
ErrLink
Stopped
{
if
err
!=
ErrLink
Down
{
t
.
Fatalf
(
"Conn.Send after NodeLink stop: %v"
,
err
)
t
.
Fatalf
(
"Conn.Send after NodeLink stop: %v"
,
err
)
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment