Companion for Substrate #13889 (#7063)

* Companion for substrate #13889

* Remove leftover

* Remove removed dependency

* Remove sp-consensus-vrf from lock

* Revert "Remove sp-consensus-vrf from lock"

This reverts commit 2269ca1e32df89272e8fd4544292204db387f436.

* Fix after substrate modifications

* Fix tests to use new VRF Signature type

* Don't rely of Deref trait

* Fix test

* Further code simplification

* Reuse garbage_vrf_signature

* update lockfile for {"substrate"}

---------

Co-authored-by: parity-processbot <>
This commit is contained in:
Davide Galassi
2023-04-19 11:43:42 +02:00
committed by GitHub
parent bef85c32be
commit 83fb51a21c
8 changed files with 240 additions and 282 deletions
@@ -24,7 +24,7 @@ use polkadot_node_network_protocol::{
view, ObservedRole,
};
use polkadot_node_primitives::approval::{
AssignmentCertKind, VRFOutput, VRFProof, RELAY_VRF_MODULO_CONTEXT,
AssignmentCertKind, VrfOutput, VrfProof, VrfSignature, RELAY_VRF_MODULO_CONTEXT,
};
use polkadot_node_subsystem::messages::{network_bridge_event, AllMessages, ApprovalCheckError};
use polkadot_node_subsystem_test_helpers as test_helpers;
@@ -265,7 +265,7 @@ fn fake_assignment_cert(block_hash: Hash, validator: ValidatorIndex) -> Indirect
validator,
cert: AssignmentCert {
kind: AssignmentCertKind::RelayVRFModulo { sample: 1 },
vrf: (VRFOutput(out), VRFProof(proof)),
vrf: VrfSignature { output: VrfOutput(out), proof: VrfProof(proof) },
},
}
}