def METHOD_NAME():
    flatbuffers_versions = MOCKED_CRATES_API_VERSIONS.get("flatbuffers").valid_versions
    unaffected_ranges = [VersionRange.from_scheme_version_spec_string("semver", "< 0.4.0")]
    affected_ranges = [
        VersionRange.from_scheme_version_spec_string("semver", ">= 0.4.0"),
        VersionRange.from_scheme_version_spec_string("semver", "<= 0.6.0"),
    ]
    resolved_ranges = [VersionRange.from_scheme_version_spec_string("semver", ">= 0.6.1")]
    unaffected_versions, affected_versions = categorize_versions(
        set(flatbuffers_versions),
        unaffected_ranges,
        affected_ranges,
        resolved_ranges,
    )
    assert len(unaffected_versions) == 2
    assert "0.3.0" in unaffected_versions
    assert "0.6.5" in unaffected_versions
    assert len(affected_versions) == 1
    assert "0.5.0" in affected_versions