Improve test coverage of the Notifications protocol (#13033)

* Add handler and upgrade tests

* Add tests for `behaviour.rs`

* Apply review comments

* Update dependencies

* Apply suggestions from code review

Co-authored-by: Dmitry Markin <dmitry@markin.tech>

* Apply review comments

* Fix clippy

* Update mockall

* Apply review comment

---------

Co-authored-by: Dmitry Markin <dmitry@markin.tech>
This commit is contained in:
Aaro Altonen
2023-02-08 11:04:02 +02:00
committed by GitHub
parent cc766cc1c5
commit 2f3f7d6b07
9 changed files with 3780 additions and 478 deletions
+4
View File
@@ -28,6 +28,7 @@ ip_network = "0.4.1"
libp2p = { version = "0.50.0", features = ["dns", "identify", "kad", "macros", "mdns", "mplex", "noise", "ping", "tcp", "tokio", "yamux", "websocket"] }
log = "0.4.17"
lru = "0.8.1"
mockall = "0.11.3"
parking_lot = "0.12.1"
pin-project = "1.0.12"
rand = "0.8.5"
@@ -52,9 +53,12 @@ sp-runtime = { version = "7.0.0", path = "../../primitives/runtime" }
[dev-dependencies]
assert_matches = "1.3"
multistream-select = "0.12.1"
rand = "0.8.5"
tempfile = "3.1.0"
tokio = { version = "1.22.0", features = ["macros"] }
tokio-util = { version = "0.7.4", features = ["compat"] }
tokio-test = "0.4.2"
sc-network-light = { version = "0.10.0-dev", path = "./light" }
sc-network-sync = { version = "0.10.0-dev", path = "./sync" }
sp-test-primitives = { version = "2.0.0", path = "../../primitives/test-primitives" }