### Question:
Ipv4 extends AbstractIp<Ipv4, Ipv4Range> { public static Ipv4 of(BigInteger from) { if(from == null) { throw new IllegalArgumentException("from cannot be null"); } return new Ipv4(from.longValue()); } protected  Ipv4(Long value); static Ipv4 of(BigInteger from); static Ipv4 of(Long value); static Ipv4 of(String value); static Ipv4 parse(String ipv4Address); @Override int compareTo(Ipv4 other); @Override String toString(); @Override Ipv4 next(); @Override Ipv4 previous(); @Override boolean hasNext(); @Override boolean hasPrevious(); @Override Ipv4Range asRange(); @Override int bitSize(); @Override BigInteger asBigInteger(); @Override Ipv4 lowerBoundForPrefix(int prefixLength); @Override Ipv4 upperBoundForPrefix(int prefixLength); @Override int getCommonPrefixLength(Ipv4 other); @Override boolean equals(Object o); @Override int hashCode(); static final int BYTE_MASK; static final int NUMBER_OF_BITS; static final long MINIMUM_VALUE; static final long MAXIMUM_VALUE; static final Ipv4 FIRST_IPV4_ADDRESS; static final Ipv4 LAST_IPV4_ADDRESS; }### Answer:
@Test public void testBuilderMethods() { Ipv4 sample = new Ipv4(1l); assertEquals(sample, Ipv4.of(BigInteger.ONE)); assertEquals(sample, Ipv4.of(1l)); assertEquals(sample, Ipv4.of("0.0.0.1")); }
@Test public void testBuilderWithNull() { thrown.expect(IllegalArgumentException.class); thrown.expectMessage("from cannot be null"); Ipv4.of((BigInteger) null); }