@Override
  public MutableAnalysisMetadataHolder setCrossProjectDuplicationEnabled(boolean isCrossProjectDuplicationEnabled) {
    checkState(!this.crossProjectDuplicationEnabled.isInitialized(), "Cross project duplication flag has already been set");
    this.crossProjectDuplicationEnabled.setProperty(isCrossProjectDuplicationEnabled);
    return this;
  }
@Test
  public void setIsCrossProjectDuplicationEnabled_throws_ISE_when_called_twice() {
    AnalysisMetadataHolderImpl underTest = new AnalysisMetadataHolderImpl(editionProvider);
    underTest.setCrossProjectDuplicationEnabled(true);

    assertThatThrownBy(() -> underTest.setCrossProjectDuplicationEnabled(false))
      .isInstanceOf(IllegalStateException.class)
      .hasMessage("Cross project duplication flag has already been set");
  }