mirror of
https://github.com/certbot/certbot.git
synced 2026-07-27 00:00:44 +02:00
End nginx configuration files with a newline
This commit is contained in:
@@ -85,7 +85,7 @@ class RawNginxDumper(object):
|
||||
|
||||
def as_string(self):
|
||||
"""Return the parsed block as a string."""
|
||||
return '\n'.join(self)
|
||||
return '\n'.join(self) + '\n'
|
||||
|
||||
|
||||
# Shortcut functions to respect Python's serialization interface
|
||||
|
||||
@@ -63,7 +63,7 @@ class TestRawNginxParser(unittest.TestCase):
|
||||
' image/jpeg jpg;\n'
|
||||
' }\n'
|
||||
' }\n'
|
||||
'}')
|
||||
'}\n')
|
||||
|
||||
def test_parse_from_file(self):
|
||||
with open(util.get_data_filename('foo.conf')) as handle:
|
||||
|
||||
Vendored
+1
-1
@@ -8,4 +8,4 @@ server {
|
||||
#
|
||||
listen 1234;
|
||||
# listen 80;
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -80,4 +80,4 @@ http {
|
||||
index index.html index.htm;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user