info.setDataProvider("DP");
info.setObservationTime("OT");
ExternalIdWithDates id = ExternalIdWithDates.of(ExternalId.of("A", "B"), LocalDate.of(2011, 6, 30), null);
ExternalIdBundleWithDates bundle = ExternalIdBundleWithDates.of(id);
info.setExternalIdBundle(bundle);
HistoricalTimeSeriesInfoDocument doc = new HistoricalTimeSeriesInfoDocument(info);
HistoricalTimeSeriesInfoDocument test = _htsMaster.add(doc);
UniqueId uniqueId = test.getUniqueId();
assertNotNull(uniqueId);
assertEquals("DbHts", uniqueId.getScheme());
assertTrue(uniqueId.isVersioned());
assertTrue(Long.parseLong(uniqueId.getValue()) >= 1000);
assertEquals("0", uniqueId.getVersion());
assertEquals(now, test.getVersionFromInstant());
assertEquals(null, test.getVersionToInstant());
assertEquals(now, test.getCorrectionFromInstant());
assertEquals(null, test.getCorrectionToInstant());
ManageableHistoricalTimeSeriesInfo testInfo = test.getInfo();
assertNotNull(testInfo);
assertEquals(uniqueId, testInfo.getUniqueId());
assertEquals("Added", testInfo.getName());
assertEquals("DF", testInfo.getDataField());
assertEquals("DS", testInfo.getDataSource());