mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Fix tests
This commit is contained in:
parent
5addb2f68f
commit
c5ab620673
2 changed files with 3 additions and 4 deletions
|
@ -150,7 +150,7 @@ def find_expected_string_keys():
|
||||||
# Global settings
|
# Global settings
|
||||||
global_config = toml.load(open(ROOT + "share/config_global.toml"))
|
global_config = toml.load(open(ROOT + "share/config_global.toml"))
|
||||||
# Boring hard-coding because there's no simple other way idk
|
# Boring hard-coding because there's no simple other way idk
|
||||||
settings_without_help_key = ["smtp_relay_host", "smtp_relay_password", "smtp_relay_port", "smtp_relay_user", "ssh_port", "ssowat_panel_overlay_enabled"]
|
settings_without_help_key = ["smtp_relay_host", "smtp_relay_password", "smtp_relay_port", "smtp_relay_user", "ssh_port", "ssowat_panel_overlay_enabled", "root_password", "root_access_explain", "root_password_confirm"]
|
||||||
|
|
||||||
for panel in global_config.values():
|
for panel in global_config.values():
|
||||||
if not isinstance(panel, dict):
|
if not isinstance(panel, dict):
|
||||||
|
|
|
@ -109,8 +109,8 @@ class SettingsConfigPanel(ConfigPanel):
|
||||||
|
|
||||||
def _apply(self):
|
def _apply(self):
|
||||||
|
|
||||||
root_password = self.new_values.pop("root_password")
|
root_password = self.new_values.pop("root_password", None)
|
||||||
root_password_confirm = self.new_values.pop("root_password_confirm")
|
root_password_confirm = self.new_values.pop("root_password_confirm", None)
|
||||||
|
|
||||||
if "root_password" in self.values:
|
if "root_password" in self.values:
|
||||||
del self.values["root_password"]
|
del self.values["root_password"]
|
||||||
|
@ -154,7 +154,6 @@ class SettingsConfigPanel(ConfigPanel):
|
||||||
self.values["root_password"] = ""
|
self.values["root_password"] = ""
|
||||||
self.values["root_password_confirm"] = ""
|
self.values["root_password_confirm"] = ""
|
||||||
|
|
||||||
|
|
||||||
def get(self, key="", mode="classic"):
|
def get(self, key="", mode="classic"):
|
||||||
|
|
||||||
result = super().get(key=key, mode=mode)
|
result = super().get(key=key, mode=mode)
|
||||||
|
|
Loading…
Add table
Reference in a new issue