Faker::PhoneNumber.cell_phone basically just calls numerify with one of the predefined phone_number_formats .
So you can just use numerify in your own format. E.g. If you want 10 digits, you would do:
Faker.numerify('#########')
If you still want to use Faker::PhoneNumber.cell_phone but want to get rid of hyphens, you can use gsub to replace the hyphen like:
Faker::PhoneNumber.cell_phone.gsub(/-/, '')
source share