On Tue, Jun 24, 2025 at 07:27:56PM +0100, Simon McVittie wrote: > > Realistically I think isolation-container and isolation-machine > > should promise that an Internet Protocol-compatible loopback > > interface always exists such that listening and connecting to ports > > on the localhost including the loopback address works. > > I think this is such a common test scenario that we should consider it to be > a guarantee even with no particular restrictions declared: technically tests > that rely on it would fail if run on a system where loopback communication > is broken, but I think it would be valid for us to say that such a system is > unreasonable and therefore those failures aren't bugs. yes, I think we can safely assume that both 127.0.0.1 can be bound to, and that `localhost` resolves correctly to it. I have written many tests that rely on those, and I have never had problems with it. One cool project would be to write a test suite to check all the properties we expect from a "good enough" test bed so we can run it using autopkgtest itself against any desired test bed to check that it actually provides both basic features that we expect to be available, and the features implied by the restrictions it claims to implement.
Attachment:
signature.asc
Description: PGP signature