@Override
  public Optional<ReadError> read(DbFileSources.Line.Builder lineBuilder) {
    if (scmReport.hasChangesetForLine(lineBuilder.getLine())) {
      Changeset changeset = scmReport.getChangesetForLine(lineBuilder.getLine());
      String author = changeset.getAuthor();
      if (author != null) {
        lineBuilder.setScmAuthor(author);
      }
      String revision = changeset.getRevision();
      if (revision != null) {
        lineBuilder.setScmRevision(revision);
      }
      lineBuilder.setScmDate(changeset.getDate());
      updateLatestChange(changeset);

      if (revision != null) {
        updateLatestChangeWithRevision(changeset);
      }
    }
    return Optional.empty();
  }
@Test
  public void set_scm() {
    ScmInfo scmInfo = new ScmInfoImpl(new Changeset[] {
      Changeset.newChangesetBuilder()
        .setAuthor("john")
        .setDate(123_456_789L)
        .setRevision("rev-1")
        .build()});

    ScmLineReader lineScm = new ScmLineReader(scmInfo);

    DbFileSources.Line.Builder lineBuilder = DbFileSources.Data.newBuilder().addLinesBuilder().setLine(1);
    assertThat(lineScm.read(lineBuilder)).isEmpty();

    assertThat(lineBuilder.getScmAuthor()).isEqualTo("john");
    assertThat(lineBuilder.getScmDate()).isEqualTo(123_456_789L);
    assertThat(lineBuilder.getScmRevision()).isEqualTo("rev-1");
  }