### Question:
NetworkAddress { public static NetworkAddress parseBlock(String networkAddress) { NetworkAddress address = null; if (networkAddress != null) { String[] split = networkAddress.split("/"); if (split.length == 2) { byte[] network = parseDottedQuad(split[0]); byte bits = Byte.parseByte(split[1]); address = toNetworkAddress(network, toNetworkMask(bits)); } else { throw new IllegalArgumentException("Network address must be ip4Address/prefixSize"); } } return address; } private  NetworkAddress(byte[] network, byte[] netmask); @Override String toString(); boolean isAddressInNetwork(String address); static NetworkAddress parse(String networkAddress); static NetworkAddress parseBlock(String networkAddress); static boolean isValidIPAddress(String networkAddress);  }### Answer:
@Test(expected = IllegalArgumentException.class) public void invalidCidrNotationNonNumeric() { NetworkAddress.parseBlock("a.b.c.d/a"); }
@Test(expected = IllegalArgumentException.class) public void invalidCidrNotationInvalidIpV4() { NetworkAddress.parseBlock("10.267.10.10/"); }
@Test(expected = IllegalArgumentException.class) public void invalidCidrNotationInvalidPrefixSize() { NetworkAddress.parseBlock("10.10.10.10/33"); }
@Test(expected = IllegalArgumentException.class) public void invalidCidrNotationInvalidPrefixSizeNegative() { NetworkAddress.parseBlock("10.10.10.10/-1"); }