### Question:
UniformSnapshot extends AbstractSnapshot { @Override public long[] getValues() { return Arrays.copyOf(values, values.length); } UniformSnapshot(Collection<Long> values);  UniformSnapshot(long[] values); @Override double getValue(double quantile); @Override int size(); @Override long[] getValues(); @Override long getMax(); @Override long getMin(); @Override double getMean(); @Override double getStdDev(); @Override void dump(OutputStream output);  }### Answer:
@Test public void hasValues() throws Exception { assertThat(snapshot.getValues()) .containsOnly(1, 2, 3, 4, 5); }
@Test public void canAlsoBeCreatedFromACollectionOfLongs() throws Exception { final Snapshot other = new UniformSnapshot(asList(5L, 1L, 2L, 3L, 4L)); assertThat(other.getValues()) .containsOnly(1, 2, 3, 4, 5); }