Major work-in-progress on the binary header specification system.

This commit is contained in:
Robert Smallshire
2015-04-26 19:10:22 +01:00
parent 25d2387d39
commit 5cfc1805e9
9 changed files with 369 additions and 236 deletions
+1 -1
View File
@@ -16,6 +16,6 @@ def multiline_ascii_encodable_text(min_num_lines, max_num_lines):
and characters which are encodable as printable 7-bit ASCII characters.
"""
return strategy(integers_in_range(0, 10)) \
return strategy(integers_in_range(min_num_lines, max_num_lines)) \
.flatmap(lambda n: ([integers_in_range(*PRINTABLE_ASCII_RANGE)],) * n) \
.map(lambda xs: '\n'.join(bytes(x).decode('ascii') for x in xs))