Exemplo n.º 1
0
 def humanize(self):
     """Returns a human readable string showing changes to the
     configuration."""
     return '\n'.join(
         '{0}: {1}'.format(key, pretty(value, width=50))
         for key, value in items(filter_hidden_settings(dict(
             (k, v) for k, v in items(self.without_defaults())
             if k.isupper() and not k.startswith('_')))))
Exemplo n.º 2
0
 def humanize(self):
     """Returns a human readable string showing changes to the
     configuration."""
     return '\n'.join(
         '%s: %s' % (key, pretty(value, width=50))
         for key, value in filter_hidden_settings(
             dict((k, v) for k, v in self.without_defaults().iteritems()
                  if k.isupper() and not k.startswith('_'))).iteritems())
Exemplo n.º 3
0
 def humanize(self, with_defaults=False, censored=True):
     """Return a human readable string showing changes to the
     configuration."""
     return '\n'.join(
         '{0}: {1}'.format(key, pretty(value, width=50))
         for key, value in items(self.table(with_defaults, censored)))
Exemplo n.º 4
0
 def test_pretty(self):
     self.assertTrue(pretty(('a', 'b', 'c')))
Exemplo n.º 5
0
 def humanize(self, with_defaults=False, censored=True):
     """Return a human readable text showing configuration changes."""
     return '\n'.join(
         '{0}: {1}'.format(key, pretty(value, width=50))
         for key, value in items(self.table(with_defaults, censored)))
Exemplo n.º 6
0
 def humanize(self):
     """Returns a human readable string showing changes to the
     configuration."""
     return '\n'.join('{0}: {1}'.format(key, pretty(value, width=50))
                      for key, value in self.without_defaults().iteritems())
Exemplo n.º 7
0
 def humanize(self):
     """Returns a human readable string showing changes to the
     configuration."""
     return '\n'.join('{0}: {1}'.format(key, pretty(value, width=50))
                     for key, value in self.without_defaults().iteritems())
Exemplo n.º 8
0
def test_pretty():
    assert pretty(('a', 'b', 'c'))
Exemplo n.º 9
0
 def humanize(self, with_defaults=False, censored=True):
     """Return a human readable text showing configuration changes."""
     return "\n".join(
         "{0}: {1}".format(key, pretty(value, width=50)) for key, value in items(self.table(with_defaults, censored))
     )
Exemplo n.º 10
0
 def test_pretty(self):
     self.assertTrue(pretty(('a', 'b', 'c')))
Exemplo n.º 11
0
 def humanize(self):
     return '\n'.join(SETTINGS_INFO % (key + ':', pretty(value, width=50))
                 for key, value in self.without_defaults().iteritems())
Exemplo n.º 12
0
def test_pretty():
    assert pretty(('a', 'b', 'c'))
Exemplo n.º 13
0
 def test_pretty(self):
     self.assertTrue(text.pretty(("a", "b", "c")))
Exemplo n.º 14
0
 def test_pretty(self):
     self.assertTrue(text.pretty(("a", "b", "c")))