private static boolean shouldSave(Map<Integer, Object> lines) {
    return lines instanceof HashMap;
  }
@Test
  public void shouldSave() {
    fileLineMeasures.setIntValue(HITS_METRIC_KEY, 1, 2);
    fileLineMeasures.setIntValue(HITS_METRIC_KEY, 3, 0);
    fileLineMeasures.save();

    assertThat(fileLineMeasures).hasToString("DefaultFileLinesContext{{hits={1=2, 3=0}}}");

    ArgumentCaptor<DefaultMeasure> captor = ArgumentCaptor.forClass(DefaultMeasure.class);
    verify(sensorStorage).store(captor.capture());

    DefaultMeasure measure = captor.getValue();
    assertThat(measure.inputComponent()).isEqualTo(file);
    assertThat(measure.metric().key()).isEqualTo(HITS_METRIC_KEY);
    assertThat(measure.value()).isEqualTo("1=2;3=0");
  }