### Question:
SparseLocalDateDoubleTimeSeries implements ImmutableBean, Serializable, LocalDateDoubleTimeSeries { @Override public Stream<LocalDate> dates() { return Stream.of(dates); } @ImmutableConstructor private  SparseLocalDateDoubleTimeSeries(LocalDate[] dates, double[] values); private  SparseLocalDateDoubleTimeSeries(LocalDate[] dates, double[] values, boolean trusted); @Override int size(); @Override boolean isEmpty(); @Override boolean containsDate(LocalDate date); @Override OptionalDouble get(LocalDate date); @Override LocalDate getLatestDate(); @Override double getLatestValue(); @Override LocalDateDoubleTimeSeries subSeries(LocalDate startInclusive, LocalDate endExclusive); @Override LocalDateDoubleTimeSeries headSeries(int numPoints); @Override LocalDateDoubleTimeSeries tailSeries(int numPoints); @Override Stream<LocalDateDoublePoint> stream(); @Override Stream<LocalDate> dates(); @Override DoubleStream values(); @Override void forEach(ObjDoubleConsumer<LocalDate> action); @Override LocalDateDoubleTimeSeries mapDates(Function<? super LocalDate, ? extends LocalDate> mapper); @Override LocalDateDoubleTimeSeries mapValues(DoubleUnaryOperator mapper); @Override LocalDateDoubleTimeSeries filter(ObjDoublePredicate<LocalDate> predicate); @Override LocalDateDoubleTimeSeriesBuilder toBuilder(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString(); static SparseLocalDateDoubleTimeSeries.Meta meta(); @Override SparseLocalDateDoubleTimeSeries.Meta metaBean();  }### Answer:
@Test public void test_of_collectionCollection_valueCollectionNull() { Collection<LocalDate> dates = dates(DATE_2011_01_01, DATE_2012_01_01); assertThatIllegalArgumentException() .isThrownBy(() -> LocalDateDoubleTimeSeries.builder().putAll(dates, (Collection<Double>) null).build()); }
@Test public void test_of_collectionCollection_valueCollectionWithNull() { Collection<LocalDate> dates = dates(DATE_2011_01_01, DATE_2012_01_01); Collection<Double> values = Arrays.asList(2d, null); assertThatIllegalArgumentException() .isThrownBy(() -> LocalDateDoubleTimeSeries.builder().putAll(dates, values).build()); }
@Test public void test_dateStream() { LocalDateDoubleTimeSeries base = LocalDateDoubleTimeSeries.builder().putAll(DATES_2010_12, VALUES_10_12).build(); assertThat(base.dates()) .containsExactly(DATE_2010_01_01, DATE_2011_01_01, DATE_2012_01_01); }
@Test public void test_combineWith_intersectionWithNoMatchingElements() { LocalDateDoubleTimeSeries series1 = LocalDateDoubleTimeSeries.builder().putAll(DATES_2010_14, VALUES_10_14).build(); List<LocalDate> dates2 = dates(DATE_2010_06_01, DATE_2011_06_01, DATE_2012_06_01, DATE_2013_06_01, DATE_2014_06_01); LocalDateDoubleTimeSeries series2 = LocalDateDoubleTimeSeries.builder().putAll(dates2, VALUES_10_14).build(); LocalDateDoubleTimeSeries test = series1.intersection(series2, Double::sum); assertThat(test).isEqualTo(LocalDateDoubleTimeSeries.empty()); }