def METHOD_NAME(produced_messages, expected_target_nevra, initramfs_path, kernel_img_path):
    target_evra = expected_target_nevra.replace('kernel-core-', '').replace('kernel-rt-core-', '')
    installed_kernel_ver = [msg for msg in produced_messages if isinstance(msg, InstalledTargetKernelVersion)]
    assert len(installed_kernel_ver) == 1, 'Actor should produce InstalledTargetKernelVersion (backwards compat.)'
    assert installed_kernel_ver[0].version == target_evra
    installed_kernel_info = [msg for msg in produced_messages if isinstance(msg, InstalledTargetKernelInfo)]
    assert len(installed_kernel_info) == 1
    assert installed_kernel_info[0].pkg_nevra == expected_target_nevra
    assert installed_kernel_info[0].initramfs_path == initramfs_path
    assert installed_kernel_info[0].kernel_img_path == kernel_img_path