@@ -0,0 +1,1094 @@
+package de.fuberlin.dynhist;%0A%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport java.util.List;%0A%0Aimport static org.junit.Assert.assertEquals;%0A%0A/**%0A * Created by Martin G%C3%B6rick%0A */%0Apublic class CompressedHistogramTest %7B%0A%0A  private double%5B%5D input;%0A  private int buckets;%0A  private Histogram histogram;%0A%0A  @Before%0A  public void setUp() %7B%0A    input = new double%5B%5D%7B1.4,1.5,1.2,1.2,2.2,4.1,5.5,3.6,2.7,2.8,6,7.2%7D;%0A    buckets = 6;%0A    histogram = new CompressedHistogram(buckets, false);%0A  %7D%0A%0A  @Test%0A  public void histogramTest() %7B%0A    for(double d : input) %7B%0A      histogram.addInput(d);%0A    %7D%0A%0A    List%3CBucket%3E hist = (List%3CBucket%3E) histogram.getHistogram();%0A    assertEquals(1.2, hist.get(0).getLeftBorder(), 0.1);%0A    assertEquals(1.4, hist.get(1).getLeftBorder(), 0.1);%0A    assertEquals(1.6, hist.get(2).getLeftBorder(), 0.1);%0A    assertEquals(3.0, hist.get(3).getLeftBorder(), 0.1);%0A    assertEquals(3.96, hist.get(4).getLeftBorder(), 0.1);%0A    assertEquals(5.36, hist.get(5).getLeftBorder(), 0.1);%0A%0A    for (Bucket bucket : hist) %7B%0A      assertEquals(2 , bucket.getCount());%0A    %7D%0A  %7D%0A%7D%0A

add testcase for compressedhistogram