It's not clear to me if dropping support for this functionality was intentional.

Chain of events:

- #21689 removed test coverage due to a misunderstanding due, I believe, to this functionality being generally supported by all platforms except macOS which does not and returns a different format
- #21756 removed support and caused this regression
- #21690 restores the test coverage that would have caught this regression

Currently, neither the test coverage before #21689 nor the coverage restored by #21690 pass since the merge of #21756.

BOOST_CHECK(Lookup("250.7.3.3"s, addr3, 9999, false));
    BOOST_CHECK(!Lookup("250.7.3.3\0example.com"s, addr3, 9999, false));
    
    CService source;
    BOOST_CHECK(Lookup("252.5.1.1", source, 8333, false));
    BOOST_CHECK(addrmanUncorrupted.Add(CAddress(addr1, NODE_NONE), source));
    BOOST_CHECK(addrmanUncorrupted.Add(CAddress(addr2, NODE_NONE), source));
    BOOST_CHECK(addrmanUncorrupted.Add(CAddress(addr3, NODE_NONE), source));
    
    CDataStream ssPeers1 = AddrmanToStream(addrmanUncorrupted);
    bool exceptionThrown = false;
    CAddrMan addrman1;
    BOOST_CHECK(addrman1.size() == 0);
    try {
        unsigned char pchMsgTmp[4];
        ssPeers1 >> pchMsgTmp;
        ssPeers1 >> addrman1;
    } catch (const std::exception&) {
        exceptionThrown = true;
    }
    BOOST_CHECK(addrman1.size() == 3);
    BOOST_CHECK(exceptionThrown == false);
    
    CDataStream ssPeers2 = AddrmanToStream(addrmanUncorrupted);
    CAddrMan addrman2;
    BOOST_CHECK(addrman2.size() == 0);
    BOOST_CHECK(CAddrDB::Read(addrman2, ssPeers2));
    BOOST_CHECK(addrman2.size() == 3);
}
BOOST_AUTO_TEST_CASE(caddrdb_read_corrupted)