mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-20 05:45:41 +00:00
Make CandidateHash a real type (#1916)
* Make `CandidateHash` a real type This pr adds a new type `CandidateHash` that is used instead of the opaque `Hash` type. This helps to ensure on the type system level that we are passing the correct types. This pr also fixes wrong usage of `relay_parent` as `candidate_hash` when communicating with the av storage. * Update core-primitives/src/lib.rs Co-authored-by: Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com> * Wrap the lines Co-authored-by: Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com>
This commit is contained in:
@@ -1635,7 +1635,7 @@ mod tests {
|
||||
use std::collections::HashMap;
|
||||
use futures::{executor, pin_mut, select, channel::mpsc, FutureExt};
|
||||
|
||||
use polkadot_primitives::v1::{BlockData, CollatorPair, PoV};
|
||||
use polkadot_primitives::v1::{BlockData, CollatorPair, PoV, CandidateHash};
|
||||
use polkadot_subsystem::messages::RuntimeApiRequest;
|
||||
use polkadot_node_primitives::{Collation, CollationGenerationConfig};
|
||||
use polkadot_node_network_protocol::{PeerId, ReputationChange, NetworkBridgeEvent};
|
||||
@@ -2273,7 +2273,7 @@ mod tests {
|
||||
|
||||
fn test_availability_store_msg() -> AvailabilityStoreMessage {
|
||||
let (sender, _) = oneshot::channel();
|
||||
AvailabilityStoreMessage::QueryAvailableData(Default::default(), sender)
|
||||
AvailabilityStoreMessage::QueryAvailableData(CandidateHash(Default::default()), sender)
|
||||
}
|
||||
|
||||
fn test_network_bridge_msg() -> NetworkBridgeMessage {
|
||||
|
||||
Reference in New Issue
Block a user