Commit c5a445d7 authored by Brian Tiger Chow's avatar Brian Tiger Chow

refactor(peer): create peer through peerstore

for safety!

use mockpeer.WithID methods to create peers in tests

License: MIT
Signed-off-by: default avatarBrian Tiger Chow <brian@perfmode.com>
parent cf153d24
package blockstore package blockstore
import ( import (
"testing"
ds "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore" ds "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore"
syncds "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore/sync" syncds "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore/sync"
"github.com/jbenet/go-ipfs/blocks" "github.com/jbenet/go-ipfs/blocks"
"testing"
) )
func TestReturnsErrorWhenSizeNegative(t *testing.T) { func TestReturnsErrorWhenSizeNegative(t *testing.T) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment