1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00

notify and gracefully skip credential-less testsa

This commit is contained in:
geemus 2010-11-22 17:49:27 -08:00
parent e61ea3c2e0
commit 1cde6c4aa9

View file

@ -28,6 +28,14 @@ if ENV["FOG_MOCK"] == "true"
Fog.mock!
end
# check to see which credentials are available and add others to the skipped tags list
all_providers = ['aws', 'bluebox', 'brightbox', 'gogrid', 'google', 'linode', 'local', 'newservers', 'rackspace', 'slicehost', 'terremark']
available_providers = Fog.providers.map {|provider| provider.to_s.downcase}
for provider in (all_providers - available_providers)
Formatador.display_line("[yellow]Skipping tests for [bold]#{provider}[/] [yellow]due to lacking credentials (add some to '~/.fog' to run them)[/]")
Thread.current[:tags] << ('-' << provider)
end
# Boolean hax
module Fog
module Boolean