### Question:
AddressStore { public boolean update(int id, Address address) { boolean result = false; if (address != null) { try (Connection connect = CON.getConnect(); PreparedStatement st = connect.prepareStatement(QUERIES.getProperty("updateAddress"))) { st.setString(1, address.getAddress()); st.setInt(2, id); result = st.executeUpdate() > 0; } catch (SQLException e) { LOG.error(e.getMessage(), e); } } return result; }  boolean add(int userId, Address address); List<Address> findAll(); Address findById(int id); boolean delete(int id); boolean update(int id, Address address); int findId(Address address);  }### Answer:
@Test public void update() { this.testStore.add(-1, new Address("test")); assertTrue(this.testStore.update(-1, new Address("test2"))); assertFalse(this.testStore.update(-100, new Address("test3"))); assertFalse(this.testStore.update(-1, null)); assertThat(this.testStore.findById(-1).getAddress(), is("test2")); }