ImmutableParameter implements Parameter { @Override public String toString() { return "(" + path + "," + operator + "," + Arrays.toString(indices) + "," + modifiers + ")"; } ImmutableParameter(String path, Set<Modifier> modifiers, int[] indices, Operator operator); @Override String getPath(); @Override Set<Modifier> getModifiers(); @Override int[] getIndices(); @Override Operator getOperator(); @Override String toString();  }
@Test public void testToString() { final ImmutableParameter parameter = new ImmutableParameter("x.y.z", Collections.emptySet(), new int[]{2, 3, 4}, new ImmutableOperator("op", 0, null)); assertThat(parameter.toString(), is("(x.y.z,op,[2, 3, 4],[])")); }