@Test
  public void detectsNullValue() throws Exception {

    ParameterAccessor accessor =
        new ParametersParameterAccessor(parameters, new Object[] {null, 5});
    assertThat(accessor.hasBindableNullValue(), is(true));

    Method method = Sample.class.getMethod("method", Pageable.class, String.class);
    DefaultParameters parameters = new DefaultParameters(method);

    accessor = new ParametersParameterAccessor(parameters, new Object[] {null, "Foo"});
    assertThat(accessor.hasBindableNullValue(), is(false));
  }
  @Test
  public void accessorIteratorHasNext() throws SecurityException, NoSuchMethodException {

    ParameterAccessor accessor =
        new ParametersParameterAccessor(parameters, new Object[] {"Foo", 2});

    Iterator<Object> iterator = accessor.iterator();
    assertThat(iterator.hasNext(), is(true));
    assertThat(iterator.next(), is((Object) "Foo"));
    assertThat(iterator.hasNext(), is(true));
    assertThat(iterator.next(), is((Object) 2));
    assertThat(iterator.hasNext(), is(false));
  }