Refactor ipam tests

Minor cleanup work