Program: 38861
Project: 38861
Buggy source:
@Test public void test() throws IOException {
  RegularTimeSeriesIndex index=RegularTimeSeriesIndex.create(Interval.parse("String_Node_Str"),Duration.ofMinutes(15));
  TimeSeriesMetadata metadata=new TimeSeriesMetadata("String_Node_Str",TimeSeriesDataType.STRING,Collections.emptyMap(),index);
  UncompressedStringArrayChunk chunk=new UncompressedStringArrayChunk(2,new String[]{"String_Node_Str","String_Node_Str"});
  CompressedStringArrayChunk chunk2=new CompressedStringArrayChunk(5,3,new String[]{"String_Node_Str","String_Node_Str"},new int[]{1,2});
  assertEquals(TimeSeriesDataType.STRING,chunk.getDataType());
  StringTimeSeries timeSeries=new StringTimeSeries(metadata,chunk,chunk2);
  assertSame(metadata,timeSeries.getMetadata());
  assertEquals(Arrays.asList(chunk,chunk2),timeSeries.getChunks());
  assertArrayEquals(new String[]{null,null,"String_Node_Str","String_Node_Str",null,"String_Node_Str","String_Node_Str","String_Node_Str"},timeSeries.toArray());
  StringPoint[] pointsRef={new StringPoint(0,Instant.parse("String_Node_Str").toEpochMilli(),null),new StringPoint(2,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(3,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(4,Instant.parse("String_Node_Str").toEpochMilli(),null),new StringPoint(5,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(6,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str")};
  assertArrayEquals(pointsRef,timeSeries.stream().toArray());
  assertArrayEquals(pointsRef,Iterators.toArray(timeSeries.iterator(),StringPoint.class));
  String jsonRef=String.join(System.lineSeparator(),"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  String json=JsonUtil.toJson(timeSeries::writeJson);
  assertEquals(jsonRef,json);
  List<TimeSeries> timeSeriesList=TimeSeries.parseJson(json);
  assertEquals(1,timeSeriesList.size());
  String json2=JsonUtil.toJson(timeSeriesList.get(0)::writeJson);
  assertEquals(json,json2);
  ObjectMapper objectMapper=new ObjectMapper().registerModule(new TimeSeriesJsonModule());
  assertEquals(timeSeries,objectMapper.readValue(objectMapper.writeValueAsString(timeSeries),StringTimeSeries.class));
}

Fixed version (ground truth):
@Test public void test() throws IOException {
  RegularTimeSeriesIndex index=RegularTimeSeriesIndex.create(Interval.parse("String_Node_Str"),Duration.ofMinutes(15));
  TimeSeriesMetadata metadata=new TimeSeriesMetadata("String_Node_Str",TimeSeriesDataType.STRING,Collections.emptyMap(),index);
  UncompressedStringArrayChunk chunk=new UncompressedStringArrayChunk(2,new String[]{"String_Node_Str","String_Node_Str"});
  CompressedStringArrayChunk chunk2=new CompressedStringArrayChunk(5,3,new String[]{"String_Node_Str","String_Node_Str"},new int[]{1,2});
  assertEquals(TimeSeriesDataType.STRING,chunk.getDataType());
  StringTimeSeries timeSeries=new StringTimeSeries(metadata,chunk,chunk2);
  assertSame(metadata,timeSeries.getMetadata());
  assertEquals(Arrays.asList(chunk,chunk2),timeSeries.getChunks());
  assertArrayEquals(new String[]{null,null,"String_Node_Str","String_Node_Str",null,"String_Node_Str","String_Node_Str","String_Node_Str"},timeSeries.toArray());
  StringPoint[] pointsRef={new StringPoint(0,Instant.parse("String_Node_Str").toEpochMilli(),null),new StringPoint(2,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(3,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(4,Instant.parse("String_Node_Str").toEpochMilli(),null),new StringPoint(5,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str"),new StringPoint(6,Instant.parse("String_Node_Str").toEpochMilli(),"String_Node_Str")};
  assertArrayEquals(pointsRef,timeSeries.stream().toArray());
  assertArrayEquals(pointsRef,Iterators.toArray(timeSeries.iterator(),StringPoint.class));
  String jsonRef=String.join(System.lineSeparator(),"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  String json=JsonUtil.toJson(timeSeries::writeJson);
  assertEquals(jsonRef,json);
  List<TimeSeries> timeSeriesList=TimeSeries.parseJson(json);
  assertEquals(1,timeSeriesList.size());
  String json2=JsonUtil.toJson(timeSeriesList.get(0)::writeJson);
  assertEquals(json,json2);
  ObjectMapper objectMapper=JsonUtil.createObjectMapper().registerModule(new TimeSeriesJsonModule());
  assertEquals(timeSeries,objectMapper.readValue(objectMapper.writeValueAsString(timeSeries),StringTimeSeries.class));
}