Skip to content

Instantly share code, notes, and snippets.

@mehlah
Last active February 5, 2016 13:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mehlah/b504e8d989fb0c37d6d2 to your computer and use it in GitHub Desktop.
Save mehlah/b504e8d989fb0c37d6d2 to your computer and use it in GitHub Desktop.
CarrierWave Fog loading issue #1870
begin
require 'bundler/inline'
rescue LoadError => e
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler'
raise e
end
gemfile(true) do
source 'https://rubygems.org'
gem 'fog-aws'
gem 'carrierwave', github: 'carrierwaveuploader/carrierwave'
end
require 'fog/aws'
require 'carrierwave'
require 'minitest/autorun'
require 'logger'
CarrierWave.configure do |config|
config.fog_provider = 'fog/aws'
config.fog_credentials = {
provider: 'AWS',
aws_access_key_id: 'xxxxxx',
aws_secret_access_key: 'yyyyyy'
}
end
class FogTest < Minitest::Test
def test_storage_constants
assert_equal [:Abstract, :File, :Fog], CarrierWave::Storage::constants
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment