bugfixes to is_ip tests