Refactor legacy indent: int -> indent: str

The type of `indent` parameter is preferably `str`. See
http://simplejson.readthedocs.io/en/latest/index.html?highlight=dump#simplejson.dump
. This change allows to specify TABs as indentation delimiter to
`pretty_format_json`. Add input validator/converter for backward compat.
This commit is contained in:
Sander Maijers 2016-06-10 20:16:00 +02:00
parent 6f2b0a27e5
commit a5628863e8
No known key found for this signature in database
GPG key ID: 2E974A73F1B0F2F7
3 changed files with 53 additions and 3 deletions

View file

@ -0,0 +1,9 @@
{
"alist": [
2,
34,
234
],
"blah": null,
"foo": "bar"
}