fix(tests): skip config.save() in config_editor unit tests

Tests using execute_action() triggered Config::save() with a default
Config, silently overwriting ~/.config/owlry/config.toml on every
`cargo test` run. Guard the save call with #[cfg(not(test))].
This commit is contained in:
2026-04-09 16:51:19 +02:00
parent e11fac3619
commit 3069c5aa5a

View File

@@ -70,6 +70,7 @@ impl ConfigProvider {
false
};
#[cfg(not(test))]
if result
&& let Err(e) = cfg.save()
{