@Test
  public void testRendersPresentationListener() throws IOException {
    lifeCycleAdapter.preserveValues(video);

    video.addPresentationListener(presentationListener);
    lifeCycleAdapter.renderChanges(video);

    JsonObject properties =
        MessageUtil.getOperationProperties(WidgetUtil.getId(video), LISTEN, null);
    assertNotNull(properties.get(Constants.EVENT_PRESENTATION));
  }
  @Test
  public void testFiresPresentationChangeToFullScreen() {
    environment.getRemoteObject().setHandler(new VideoOperationHandler(video));
    video.addPresentationListener(presentationListener);
    JsonObject parameters = new JsonObject();
    parameters.add(PROPERTY_PRESENTATION, Presentation.FULL_SCREEN.name());

    environment.dispatchNotify(Constants.EVENT_PRESENTATION, parameters);

    verify(presentationListener).presentationChanged(Presentation.FULL_SCREEN);
  }