diff options
author | Javier Peletier <jm@epiclabs.io> | 2018-09-30 15:51:11 +0800 |
---|---|---|
committer | Javier Peletier <jm@epiclabs.io> | 2018-10-03 15:12:06 +0800 |
commit | b6ccc06cdaac80d09da17c25b2f450cd1f1b7914 (patch) | |
tree | 2413da1a2025e901eecf253399fe4bfebbdd1925 /swarm/api/client/client_test.go | |
parent | 83705ef6aa3645a6305a400fa175e44904a929f7 (diff) | |
download | go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar.gz go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar.bz2 go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar.lz go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar.xz go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.tar.zst go-tangerine-b6ccc06cdaac80d09da17c25b2f450cd1f1b7914.zip |
swarm/storage/feeds: Final package rename and moved files
Diffstat (limited to 'swarm/api/client/client_test.go')
-rw-r--r-- | swarm/api/client/client_test.go | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/swarm/api/client/client_test.go b/swarm/api/client/client_test.go index fbc49a6e1..4fad7fbc7 100644 --- a/swarm/api/client/client_test.go +++ b/swarm/api/client/client_test.go @@ -25,14 +25,14 @@ import ( "sort" "testing" - "github.com/ethereum/go-ethereum/swarm/storage/mru/lookup" + "github.com/ethereum/go-ethereum/swarm/storage/feeds/lookup" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/swarm/api" swarmhttp "github.com/ethereum/go-ethereum/swarm/api/http" "github.com/ethereum/go-ethereum/swarm/multihash" - "github.com/ethereum/go-ethereum/swarm/storage/mru" + "github.com/ethereum/go-ethereum/swarm/storage/feeds" "github.com/ethereum/go-ethereum/swarm/testutil" ) @@ -361,12 +361,12 @@ func TestClientMultipartUpload(t *testing.T) { } } -func newTestSigner() (*mru.GenericSigner, error) { +func newTestSigner() (*feeds.GenericSigner, error) { privKey, err := crypto.HexToECDSA("deadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef") if err != nil { return nil, err } - return mru.NewGenericSigner(privKey), nil + return feeds.NewGenericSigner(privKey), nil } // test the transparent resolving of multihash feed updates with bzz:// scheme @@ -394,9 +394,9 @@ func TestClientCreateFeedMultihash(t *testing.T) { mh := multihash.ToMultihash(s) // our feed topic - topic, _ := mru.NewTopic("foo.eth", nil) + topic, _ := feeds.NewTopic("foo.eth", nil) - createRequest := mru.NewFirstRequest(topic) + createRequest := feeds.NewFirstRequest(topic) createRequest.SetData(mh) if err := createRequest.Sign(signer); err != nil { @@ -448,8 +448,8 @@ func TestClientCreateUpdateFeed(t *testing.T) { databytes := []byte("En un lugar de La Mancha, de cuyo nombre no quiero acordarme...") // our feed topic name - topic, _ := mru.NewTopic("El Quijote", nil) - createRequest := mru.NewFirstRequest(topic) + topic, _ := feeds.NewTopic("El Quijote", nil) + createRequest := feeds.NewFirstRequest(topic) createRequest.SetData(databytes) if err := createRequest.Sign(signer); err != nil { @@ -479,7 +479,7 @@ func TestClientCreateUpdateFeed(t *testing.T) { // define different data databytes = []byte("... no ha mucho tiempo que vivĂa un hidalgo de los de lanza en astillero ...") - updateRequest, err := client.GetFeedMetadata(nil, correctManifestAddrHex) + updateRequest, err := client.GetFeedRequest(nil, correctManifestAddrHex) if err != nil { t.Fatalf("Error retrieving update request template: %s", err) } @@ -508,12 +508,12 @@ func TestClientCreateUpdateFeed(t *testing.T) { // now try retrieving feed updates without a manifest - feed := &mru.Feed{ + feed := &feeds.Feed{ Topic: topic, User: signer.Address(), } - lookupParams := mru.NewQueryLatest(feed, lookup.NoClue) + lookupParams := feeds.NewQueryLatest(feed, lookup.NoClue) reader, err = client.QueryFeed(lookupParams, "") if err != nil { t.Fatalf("Error retrieving feed updates: %s", err) |