Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-bitswap
Commits
51d5dc02
Commit
51d5dc02
authored
Sep 21, 2014
by
Brian Tiger Chow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(bitswap:testnet) Provide takes ctx
parent
d345da7d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
testnet/routing.go
testnet/routing.go
+1
-1
testnet/routing_test.go
testnet/routing_test.go
+1
-1
No files found.
testnet/routing.go
View file @
51d5dc02
...
...
@@ -92,6 +92,6 @@ func (a *routingClient) FindProvidersAsync(ctx context.Context, k u.Key, max int
return
out
}
func
(
a
*
routingClient
)
Provide
(
key
u
.
Key
)
error
{
func
(
a
*
routingClient
)
Provide
(
_
context
.
Context
,
key
u
.
Key
)
error
{
return
a
.
hashTable
.
Announce
(
a
.
peer
,
key
)
}
testnet/routing_test.go
View file @
51d5dc02
...
...
@@ -53,7 +53,7 @@ func TestClientFindProviders(t *testing.T) {
rs
:=
VirtualRoutingServer
()
client
:=
rs
.
Client
(
peer
)
k
:=
u
.
Key
(
"hello"
)
err
:=
client
.
Provide
(
k
)
err
:=
client
.
Provide
(
context
.
Background
(),
k
)
if
err
!=
nil
{
t
.
Fatal
(
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