@Test
public void shouldThrowIfGO_ARTIFACTS_S3_BUCKETNotPresent() {

    Map<String, String> mockVariables = mockEnvironmentVariables.with(GO_ARTIFACTS_S3_BUCKET, "").build();
    Config config = new Config(Maps.builder()
            .with(Constants.SOURCEDESTINATIONS, Maps.builder().with("value", "[{\"source\": \"target/*\", \"destination\": \"\"}]").build())
            .with(Constants.DESTINATION_PREFIX, Maps.builder().with("value", "").build())
            .with(Constants.ARTIFACTS_BUCKET, Maps.builder().with("value", "").build())
            .build());
    TaskExecutionResult result = publishExecutor.execute(config, mockContext(mockVariables));
    assertFalse(result.isSuccessful());
    assertThat(result.message(), is("GO_ARTIFACTS_S3_BUCKET environment variable is not set"));
}