1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/tests/serverlove/util/compute/password_generator_tests.rb

19 lines
528 B
Ruby
Raw Normal View History

require 'fog/serverlove/util/compute/password_generator'
Shindo.tests('Fog::Compute::Serverlove::PasswordGenerator | generate password', ['serverlove']) do
@password = Fog::Compute::Serverlove::PasswordGenerator.generate
tests("@password.length").returns(8) do
@password.length
end
tests("@password contains one capital letter").returns(true) do
@password.match(/[A-Z]/) && true
end
tests("@password contains one lower case letter").returns(true) do
@password.match(/[a-z]/) && true
end
end