@PostConstruct
    public void applyPluginMetadata() {
        String pluginId = getPluginId();
        for (ConfigurationProperty configurationProperty : configuration) {
            SCMMetadataStore scmMetadataStore = SCMMetadataStore.getInstance();
            if (scmMetadataStore.getConfigurationMetadata(pluginId) != null) {
                boolean isSecureProperty = scmMetadataStore.hasOption(pluginId, configurationProperty.getConfigurationKey().getName(), SCMConfiguration.SECURE);
                configurationProperty.handleSecureValueConfiguration(isSecureProperty);
            }
        }
    }
@Test
    void shouldNotUpdateSecurePropertyWhenPluginIsMissing() {
        GoCipher goCipher = new GoCipher();

        ConfigurationProperty secureProperty = new ConfigurationProperty(new ConfigurationKey("key1"), null, new EncryptedConfigurationValue("value"), goCipher);
        ConfigurationProperty nonSecureProperty = new ConfigurationProperty(new ConfigurationKey("key2"), new ConfigurationValue("value1"), null, goCipher);
        SCM scm = SCMMother.create("scm-id", "scm-name", "plugin-id", "version", new Configuration(secureProperty, nonSecureProperty));

        scm.applyPluginMetadata();

        assertThat(secureProperty.getEncryptedConfigurationValue()).isNotNull();
        assertThat(secureProperty.getConfigurationValue()).isNull();

        assertThat(nonSecureProperty.getConfigurationValue()).isNotNull();
        assertThat(nonSecureProperty.getEncryptedConfigurationValue()).isNull();
    }