Go 1.25rc1 includes the new exciting and no-longer-experimental
testing/synctest package.
To make use of synctest in your tests of network code, you'll need to mock,
or simulate the network.
Gosimnet not only mocks (simulates) the network in a way that
enables synctest bubbles to block, but also allows you to isolate servers,
and to inject asymmetric and probabilistic network card faults into the mock.
A whole set of faults and be applied, and reversed, with a single call.
I've fleshed out the API for fault modeling recently. You can see the API description here.
https://github.com/glycerine/gosimnet?tab=readme-ov-file#network-modeling-api-summary
It is not set in stone yet, to allow for your feedback.
Enjoy.
Jason