def _create_mock_signed_attestation(state: BeaconState, attestation_data: AttestationData, attestation_slot: Slot, committee: Sequence[ValidatorIndex], num_voted_attesters: int, keymap: Dict[(BLSPubkey, int)], slots_per_epoch: int) -> Attestation:
    '\n    Create a mocking attestation of the given ``attestation_data`` slot with ``keymap``.\n    '
    (message_hash, attesting_indices) = _get_mock_message_and_attesting_indices(attestation_data, committee, num_voted_attesters)
    signatures = [sign_transaction(message_hash=message_hash, privkey=keymap[state.validators[committee[committee_index]].pubkey], state=state, slot=attestation_slot, signature_domain=SignatureDomain.DOMAIN_ATTESTATION, slots_per_epoch=slots_per_epoch) for committee_index in attesting_indices]
    (aggregation_bits, aggregate_signature) = aggregate_votes(bitfield=get_empty_bitfield(len(committee)), sigs=(), voting_sigs=signatures, attesting_indices=attesting_indices)
    return Attestation(aggregation_bits=aggregation_bits, data=attestation_data, custody_bits=Bitfield(((False,) * len(aggregation_bits))), signature=aggregate_signature)
Create a mocking attestation of the given ``attestation_data`` slot with ``keymap``.
def _create_mock_signed_attestation(state: BeaconState, attestation_data: AttestationData, attestation_slot: Slot, committee: Sequence[ValidatorIndex], num_voted_attesters: int, keymap: Dict[(BLSPubkey, int)], slots_per_epoch: int) -> Attestation:
    '\n    \n    '
    (message_hash, attesting_indices) = _get_mock_message_and_attesting_indices(attestation_data, committee, num_voted_attesters)
    signatures = [sign_transaction(message_hash=message_hash, privkey=keymap[state.validators[committee[committee_index]].pubkey], state=state, slot=attestation_slot, signature_domain=SignatureDomain.DOMAIN_ATTESTATION, slots_per_epoch=slots_per_epoch) for committee_index in attesting_indices]
    (aggregation_bits, aggregate_signature) = aggregate_votes(bitfield=get_empty_bitfield(len(committee)), sigs=(), voting_sigs=signatures, attesting_indices=attesting_indices)
    return Attestation(aggregation_bits=aggregation_bits, data=attestation_data, custody_bits=Bitfield(((False,) * len(aggregation_bits))), signature=aggregate_signature)