@Test
  public void testGetLocation() throws Exception {
    final ChartHelper chartHelper = new ChartHelper(getChart());

    assertNull(chartHelper.getLocation());
    chartHelper.generate(512, 384);
    assertNotNull(chartHelper.getLocation());
  }
  @Test
  public void testGetImageMap() throws Exception {
    final ChartHelper chartHelper = new ChartHelper(getChart());

    try {
      assertNull(chartHelper.getImageMap());
      fail("should have thrown NPE.");
    } catch (NullPointerException e) {
      // yay
    }
    chartHelper.generate(512, 384);
    assertNotNull(chartHelper.getImageMap());
    assertNotNull(chartHelper.getImageMapName());
  }