Ignore empty sections in notes
Users may do this, and it doesn't make sense to explode when a valid section is stated but empty. Change-Id: I1b30be6122893563cdc4c41172e28ed5a69a0e3c Closes-Bug: #1588992
This commit is contained in:
parent
38b015817e
commit
45878e06b2
@ -68,6 +68,7 @@ def format_report(loader, versions_to_include, title=None):
|
||||
notes = [
|
||||
n
|
||||
for fn, sha in notefiles
|
||||
if file_contents[fn].get(section_name)
|
||||
for n in file_contents[fn].get(section_name, [])
|
||||
]
|
||||
if notes:
|
||||
|
@ -42,6 +42,7 @@ class TestFormatter(base.TestCase):
|
||||
'features': [
|
||||
'We added a feature!',
|
||||
],
|
||||
'upgrade': None,
|
||||
},
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user