[net] restructure netif_test
[net] test invalid ips
[js] add debug.assert_exception() utility function for validating exception returning code
[tests] use debug.assert_exception() where applicable