@Udf
  public Long round(@UdfParameter final long val) {
    return val;
  }
@Test
  public void shouldRoundDoubleWithDecimalPlacesNegative() {
    assertThat(udf.round(-1.0d, 0), is(-1.0d));
    assertThat(udf.round(-1.1d, 0), is(-1.0d));
    assertThat(udf.round(-1.5d, 0), is(-1.0d));
    assertThat(udf.round(-1.75d, 0), is(-2.0d));
    assertThat(udf.round(-100.1d, 0), is(-100.0d));
    assertThat(udf.round(-100.5d, 0), is(-100.0d));
    assertThat(udf.round(-100.75d, 0), is(-101.0d));
    assertThat(udf.round(-100.10d, 1), is(-100.1d));
    assertThat(udf.round(-100.11d, 1), is(-100.1d));
    assertThat(udf.round(-100.15d, 1), is(-100.1d));
    assertThat(udf.round(-100.17d, 1), is(-100.2d));
    assertThat(udf.round(-100.110d, 2), is(-100.11d));
    assertThat(udf.round(-100.111d, 2), is(-100.11d));
    assertThat(udf.round(-100.115d, 2), is(-100.11d));
    assertThat(udf.round(-100.117d, 2), is(-100.12d));
    assertThat(udf.round(-100.1110d, 3), is(-100.111d));
    assertThat(udf.round(-100.1111d, 3), is(-100.111d));
    assertThat(udf.round(-100.1115d, 3), is(-100.111d));
    assertThat(udf.round(-100.1117d, 3), is(-100.112d));
    assertThat(udf.round(-12345.67d, -1), is(-12350d));
    assertThat(udf.round(-12345.67d, -2), is(-12300d));
    assertThat(udf.round(-12345.67d, -3), is(-12000d));
    assertThat(udf.round(-12345.67d, -4), is(-10000d));
    assertThat(udf.round(-12345.67d, -5), is(0d));
  }