@Test
public void testGenericP1Y() throws Exception {

    SdmxSource source = new GenericDocFactory().create(load("generic-P1Y.xml"));
    assertEquals(3, source.items.size());
    SdmxSeries series;
    TsData data;
    series = (SdmxSeries) source.items.get(0);
    assertEquals(TimeFormat.P1Y, series.timeFormat);
    assertEquals("NADET2008_INDICATOR=B1G, NADET2008_BRANCH=A38_AA, NADET2008_SECTOR=S1, NADET2008_PRICE=L, FREQUENCY=A", series.id);
    data = series.data.get();
    assertEquals(new TsDomain(TsFrequency.Yearly, 2009, 0, 5), data.getDomain());
    assertArrayEquals(new double[]{2722.8, 2911.5, 2836.2, 2708.5, 2797.7}, data.internalStorage(), 0);
    series = (SdmxSeries) source.items.get(2);
    assertEquals(TimeFormat.P1Y, series.timeFormat);
    assertEquals("NADET2008_INDICATOR=B1G, NADET2008_BRANCH=A38_AA, NADET2008_SECTOR=S11, NADET2008_PRICE=V, FREQUENCY=A", series.id);
    data = series.data.get();
    assertEquals(new TsDomain(TsFrequency.Yearly, 2009, 0, 5), data.getDomain());
    assertArrayEquals(new double[]{705.6, 815.8, 882.2, 960, 1199.4}, data.internalStorage(), 0);
}