### Question:
NameOrCrn { public boolean hasCrn() { return isNotEmpty(crn); } private  NameOrCrn(String name, String crn); static NameOrCrn ofName(String name); static NameOrCrn ofCrn(String crn); static NameOrCrn empty(); String getName(); String getCrn(); boolean hasName(); boolean hasCrn(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test public void testHasCrn() { NameOrCrn nameOrCrn = NameOrCrn.ofCrn(CRN); assertTrue(nameOrCrn.hasCrn()); }