### Question:
ImmutableQuery implements Query { @Override public boolean hasParameter(String paramName) { return this.parameters.containsKey(paramName); } private  ImmutableQuery(Map<String, ImmutableQueryParameter> params); @Override boolean isEmpty(); @Override int size(); @Override boolean hasParameter(String paramName); @Override Parameter getParameter(String paramName); @Override String toString(); @Override Set<String> parameterNames();  }### Answer:
@Test public void testHasAllParameterNames() { assertThat(queryWithParameters().hasParameter(PARAMETER_1),equalTo(true)); assertThat(queryWithParameters().hasParameter(PARAMETER_2),equalTo(true)); }
@Test public void testHasNoOtherParameterNames() { assertThat(queryWithParameters().hasParameter(UNEXISTING_PARAMETER),equalTo(false)); }