@Test
public void testPublishers() {

    MediatorConfigurationSupport support = create("publisherPublisherOfMessage");
    MediatorConfigurationSupport.ValidationOutput output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherMultiOfMessage");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherPublisherOfPayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherMultiOfPayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherPublisherBuilderOfMessage");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isTrue();
    support = create("publisherPublisherBuilderOfPayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.STREAM_OF_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isTrue();
    support = create("publisherGeneratePayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.INDIVIDUAL_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherGenerateMessage");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.INDIVIDUAL_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherGenerateCompletionStagePayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.COMPLETION_STAGE_OF_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherGenerateCompletionStageMessage");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.COMPLETION_STAGE_OF_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherGenerateUniPayload");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.UNI_OF_PAYLOAD);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
    support = create("publisherGenerateUniMessage");
    output = support.validate(Shape.PUBLISHER, null);
    assertThat(output.getConsumption()).isEqualTo(MediatorConfiguration.Consumption.NONE);
    assertThat(output.getProduction()).isEqualTo(MediatorConfiguration.Production.UNI_OF_MESSAGE);
    assertThat(output.getIngestedPayloadType()).isNull();
    assertThat(output.getUseBuilderTypes()).isFalse();
}