use of com.radixdlt.consensus.BFTHeader in project radixdlt by radixdlt.
the class VerifiedVertexStoreStateCreationTest method creating_vertex_store_with_qc_not_matching_vertex_should_fail.
@Test
public void creating_vertex_store_with_qc_not_matching_vertex_should_fail() {
BFTHeader genesisHeader = new BFTHeader(View.of(0), HashUtils.random256(), mock(LedgerHeader.class));
VoteData voteData = new VoteData(genesisHeader, genesisHeader, genesisHeader);
QuorumCertificate badRootQC = new QuorumCertificate(voteData, new TimestampedECDSASignatures());
assertThatThrownBy(() -> VerifiedVertexStoreState.create(HighQC.from(badRootQC), genesisVertex, Optional.empty(), hasher)).isInstanceOf(IllegalStateException.class);
}
Aggregations