Sha256: 7758fb5a8544eaa18025edcd2fb176053887faadcaa82c5aa7dad9733f0da3a6

Contents?: true

Size: 558 Bytes

Versions: 32

Compression:

Stored size: 558 Bytes

Contents

def random_email_address
  "#{random_string}@example.com"
end

def random_string
  random_alpha_string_of_length(10)
end

def random_alpha_string_of_length(length)
  letters = *'a'..'z'
  random_string_for_uniqueness = ''
  length.times { random_string_for_uniqueness += letters[rand(letters.size - 1)]}
  random_string_for_uniqueness
end

def random_number_string_of_length(length)
  numbers = *'0'..'9'
  random_string_for_uniqueness = ''
  length.times { random_string_for_uniqueness += numbers[rand(numbers.size - 1)]}
  random_string_for_uniqueness
end

Version data entries

32 entries across 32 versions & 8 rubygems

Version Path
cameroncox-mousetrap-0.5.3.2 spec/support/random_data.rb
cameroncox-mousetrap-0.5.3.1 spec/support/random_data.rb
cameroncox-mousetrap-0.5.3 spec/support/random_data.rb
cameroncox-mousetrap-0.5.2 spec/support/random_data.rb
cameroncox-mousetrap-0.5.1 spec/support/random_data.rb
mousetrap-0.5.0 spec/support/random_data.rb
mousetrap-0.4.4 spec/support/random_data.rb
mousetrap-0.4.3 spec/support/random_data.rb
mousetrap-0.4.2 spec/support/random_data.rb
mousetrap-0.4.1 spec/support/random_data.rb
mousetrap-0.4.0 spec/support/random_data.rb
mousetrap-0.3.3 spec/support/random_data.rb