PersonRecord { public boolean isUnknown() { return _id <= 0; } PersonRecord(long id, String name, String email, String number); boolean isUnknown(); Address getAddress(AddressStyle style); String getEmail(); String getId(); long getContactId(); String getNumber(); String getName(); String toString();  }
@Test public void shouldBeUnknownForInvalidIds() throws Exception { PersonRecord record = new PersonRecord(0, null, null, "-1"); assertThat(record.isUnknown()).isTrue(); }
@Test public void shouldNotBeUnknownForValidIds() throws Exception { PersonRecord record = new PersonRecord(12, null, null, "-1"); assertThat(record.isUnknown()).isFalse(); }