### Question:
CustomerCore extends Customer { @Override public String toString() { var roles = Arrays.toString(this.roles.keySet().toArray()); return "Customer{roles=" + roles + "}"; } 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 toStringTest() { var core = new CustomerCore(); core.addRole(Role.Borrower); assertEquals(core.toString(), "Customer{roles=[Borrower]}"); core = new CustomerCore(); core.addRole(Role.Investor); assertEquals(core.toString(), "Customer{roles=[Investor]}"); core = new CustomerCore(); assertEquals(core.toString(), "Customer{roles=[]}"); }