WithFilter attaches a filter to the context. Any connection accepted or dialed with the debug protocol using this context will be wrapped via a call to filter.
Filters give you the chance to add your own logic to flow.Conns that get created. This is useful in tests. For example you might want to modify all packets, print them out, or perhaps cause errors.