@Test
public void testGetLast() {

    StreamEvent event = createStreamEvent("Dell", 245.95, 78);
    addStreamEvent(event);
    addStreamEvent(createStreamEvent("Hp", 210.45, 23));
    addStreamEvent(createStreamEvent("Apple", 3500.50, 10));
    Assert.assertEquals(event, (StreamEvent) window.getLast(false));
    Assert.assertEquals(event, (StreamEvent) window.getLast(true));
    Assert.assertNotSame(event, (StreamEvent) window.getLast(false));
}