### Question:
CustomerCore extends Customer { @Override public boolean hasRole(Role role) { return roles.containsKey(role); } CustomerCore(); @Override boolean addRole(Role role); @Override boolean hasRole(Role role); @Override boolean remRole(Role role); @Override Optional<T> getRole(Role role, Class<T> expectedRole); @Override String toString();  }### Answer:
@Test public void hasRole() { var core = new CustomerCore(); core.addRole(Role.Borrower); assertTrue(core.hasRole(Role.Borrower)); assertFalse(core.hasRole(Role.Investor)); }