tests/basics: Add test for string module formatting with int argument.
This commit is contained in:
parent
3a0b2be6e2
commit
b154468b08
7
tests/basics/string_format_modulo_int.py
Normal file
7
tests/basics/string_format_modulo_int.py
Normal file
@ -0,0 +1,7 @@
|
||||
# test string modulo formatting with int values
|
||||
|
||||
# test + option with various amount of padding
|
||||
for pad in ('', ' ', '0'):
|
||||
for n in (1, 2, 3):
|
||||
for val in (-1, 0, 1):
|
||||
print(('%+' + pad + str(n) + 'd') % val)
|
Loading…
x
Reference in New Issue
Block a user