@Override
    public void validate(ValidationContext validationContext) {
        artifactsDir.validate(validationContext);
        purgeSettings.validate(validationContext);
    }
@Test
    void shouldValidateArtifactDirectoryAndPurgeSetting() {
        ArtifactConfig artifactConfig = new ArtifactConfig();
        artifactConfig.setArtifactsDir(mock(ArtifactDirectory.class));
        artifactConfig.setPurgeSettings(mock(PurgeSettings.class));

        artifactConfig.validate(null);

        verify(artifactConfig.getArtifactsDir(), times(1)).validate(null);
        verify(artifactConfig.getPurgeSettings(), times(1)).validate(null);
    }