Currently, link_flap test works in such way: it figures out all the connections between the DUT and the fan-out switch, and in a random order, it turn off a fan-out switch port, checking to make sure that all DUT ports except the affected port are still up, and the affected port is down. Then turn on the fan-out switch port and check all DUT ports are up. It repeats the check until all connections are tested.
We think that the test could be improved by also checking all relevant fan-out switch ports, making sure that by turning off one fan-out switch port, all other relevant fan-out switch ports are still up and healthy.