Add test to check setting max conenctions does not crash any processes

This is a regression test to prevent a previous bug.