mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #50289 from gtmanfred/2018.3
ignore empty line in localectl status output
This commit is contained in:
commit
935f1815a2
2 changed files with 5 additions and 1 deletions
|
@ -79,6 +79,8 @@ def _localectl_status():
|
|||
ctl_key = ctl_key.strip().lower().replace(' ', '_')
|
||||
else:
|
||||
ctl_data = line.strip()
|
||||
if not ctl_data:
|
||||
continue
|
||||
if ctl_key:
|
||||
if '=' in ctl_data:
|
||||
loc_set = ctl_data.split('=')
|
||||
|
|
|
@ -41,9 +41,11 @@ class LocalemodTestCase(TestCase, LoaderModuleMockMixin):
|
|||
X11 Model: pc105
|
||||
'''
|
||||
locale_ctl_notset = '''
|
||||
System Locale: n/a
|
||||
System Locale: n/a
|
||||
|
||||
VC Keymap: n/a
|
||||
X11 Layout: n/a
|
||||
X11 Model: n/a
|
||||
'''
|
||||
locale_ctl_out_empty = ''
|
||||
locale_ctl_out_broken = '''
|
||||
|
|
Loading…
Add table
Reference in a new issue