def test_egg_info_matches(egg_info, canonical_name, expected): version = _egg_info_matches(egg_info, canonical_name) assert version == expected