1
0
mirror of https://github.com/askn/faker.git synced 2023-08-10 21:13:01 +03:00

add number

This commit is contained in:
Aşkın Gedik
2016-01-06 15:16:07 +02:00
parent 930398a41e
commit 099dce6fc3
3 changed files with 23 additions and 0 deletions

11
src/faker/number.cr Normal file
View File

@@ -0,0 +1,11 @@
module Faker
class Number
def self.number(digits)
(1..digits).map { digit }.join ""
end
def self.digit
rand(10).to_s
end
end
end