mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 02:42:27 +00:00
swarm/network/stream: fixed invalid price check
This commit is contained in:
parent
e3be2ed3ab
commit
00c250e4d0
1 changed files with 2 additions and 2 deletions
|
|
@ -943,12 +943,12 @@ func TestHasPriceImplementation(t *testing.T) {
|
|||
t.Fatal("`Registry` does not have the expected Prices instance")
|
||||
}
|
||||
price := pricesInstance.Price(&ChunkDeliveryMsgRetrieval{})
|
||||
if price == nil || price.Value == 0 && price.Value != pricesInstance.getChunkDeliveryMsgRetrievalPrice() {
|
||||
if price == nil || price.Value == 0 || price.Value != pricesInstance.getChunkDeliveryMsgRetrievalPrice() {
|
||||
t.Fatal("No prices set for chunk delivery msg")
|
||||
}
|
||||
|
||||
price = pricesInstance.Price(&RetrieveRequestMsg{})
|
||||
if price == nil || price.Value == 0 && price.Value != pricesInstance.getRetrieveRequestMsgPrice() {
|
||||
if price == nil || price.Value == 0 || price.Value != pricesInstance.getRetrieveRequestMsgPrice() {
|
||||
t.Fatal("No prices set for chunk delivery msg")
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue