tests: Add some more tests for bytes, bignum, string and ujson.

This commit is contained in:
Damien George
2015-03-14 21:20:58 +00:00
parent 0683c1ceef
commit 26a9975fba
12 changed files with 34 additions and 0 deletions

View File

@@ -6,6 +6,7 @@ full_tests = False
def test(fmt, *args):
print('{:8s}'.format(fmt) + '>' + fmt.format(*args) + '<')
test("}}{{")
test("{}-{}", 1, [4, 5])
test("{0}-{1}", 1, [4, 5])
test("{1}-{0}", 1, [4, 5])
@@ -40,6 +41,7 @@ test("{:#4X}", 0)
test("{:<6s}", "ab")
test("{:>6s}", "ab")
test("{:^6s}", "ab")
test("{:.1s}", "ab")
test("{: <6d}", 123)
test("{: <6d}", -123)