Method: PropCheck::Generators.printable_char
- Defined in:
- lib/prop_check/generators.rb
.printable_char ⇒ Object
Generates a single-character printable string both ASCII characters and Unicode.
Shrinks towards characters with lower codepoints, e.g. ASCII
>> Generators.printable_char.sample(size: 10, rng: Random.new(42))
=> ["吏", "", "", "", "", "", "", "", "", "Ȍ"]
599 600 601 |
# File 'lib/prop_check/generators.rb', line 599 def printable_char one_of(*@@printable_chars.map(&method(:constant))) end |