carrierwave-dropbox 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +17 -0
- data/.rspec +1 -0
- data/Gemfile +4 -0
- data/LICENSE +22 -0
- data/README.md +82 -0
- data/Rakefile +6 -0
- data/carrierwave-dropbox.gemspec +32 -0
- data/lib/carrierwave/dropbox.rb +18 -0
- data/lib/carrierwave/dropbox/authorize.rake +13 -0
- data/lib/carrierwave/dropbox/railtie.rb +9 -0
- data/lib/carrierwave/dropbox/rake.rb +41 -0
- data/lib/carrierwave/dropbox/version.rb +5 -0
- data/lib/carrierwave/storage/dropbox.rb +62 -0
- data/spec/carrierwave-uploader-base_spec.rb +18 -0
- data/spec/dummy/.gitignore +16 -0
- data/spec/dummy/Gemfile +11 -0
- data/spec/dummy/Rakefile +6 -0
- data/spec/dummy/app/controllers/application_controller.rb +5 -0
- data/spec/dummy/app/controllers/articles_controller.rb +58 -0
- data/spec/dummy/app/controllers/concerns/.keep +0 -0
- data/spec/dummy/app/helpers/application_helper.rb +2 -0
- data/spec/dummy/app/helpers/articles_helper.rb +2 -0
- data/spec/dummy/app/mailers/.keep +0 -0
- data/spec/dummy/app/models/.keep +0 -0
- data/spec/dummy/app/models/article.rb +3 -0
- data/spec/dummy/app/models/concerns/.keep +0 -0
- data/spec/dummy/app/uploaders/image_uploader.rb +19 -0
- data/spec/dummy/app/views/articles/_form.html.erb +29 -0
- data/spec/dummy/app/views/articles/edit.html.erb +6 -0
- data/spec/dummy/app/views/articles/index.html.erb +31 -0
- data/spec/dummy/app/views/articles/new.html.erb +5 -0
- data/spec/dummy/app/views/articles/show.html.erb +1 -0
- data/spec/dummy/app/views/layouts/application.html.erb +12 -0
- data/spec/dummy/bin/bundle +3 -0
- data/spec/dummy/bin/rails +4 -0
- data/spec/dummy/bin/rake +4 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +23 -0
- data/spec/dummy/config/boot.rb +4 -0
- data/spec/dummy/config/database.yml +25 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +29 -0
- data/spec/dummy/config/environments/production.rb +80 -0
- data/spec/dummy/config/environments/test.rb +36 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/carrierwave.rb +8 -0
- data/spec/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/dummy/config/initializers/inflections.rb +16 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +12 -0
- data/spec/dummy/config/initializers/session_store.rb +3 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/en.yml +23 -0
- data/spec/dummy/config/routes.rb +58 -0
- data/spec/dummy/db/migrate/20130801141015_create_articles.rb +11 -0
- data/spec/dummy/db/schema.rb +24 -0
- data/spec/dummy/db/seeds.rb +7 -0
- data/spec/dummy/public/404.html +58 -0
- data/spec/dummy/public/422.html +58 -0
- data/spec/dummy/public/500.html +57 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/public/robots.txt +5 -0
- data/spec/features/upload_file_spec.rb +32 -0
- data/spec/fixtures/ruby.png +0 -0
- data/spec/spec_helper.rb +15 -0
- metadata +307 -0
| @@ -0,0 +1,14 @@ | |
| 1 | 
            +
            # Be sure to restart your server when you modify this file.
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            # This file contains settings for ActionController::ParamsWrapper which
         | 
| 4 | 
            +
            # is enabled by default.
         | 
| 5 | 
            +
             | 
| 6 | 
            +
            # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
         | 
| 7 | 
            +
            ActiveSupport.on_load(:action_controller) do
         | 
| 8 | 
            +
              wrap_parameters format: [:json] if respond_to?(:wrap_parameters)
         | 
| 9 | 
            +
            end
         | 
| 10 | 
            +
             | 
| 11 | 
            +
            # To enable root element in JSON for ActiveRecord objects.
         | 
| 12 | 
            +
            # ActiveSupport.on_load(:active_record) do
         | 
| 13 | 
            +
            #  self.include_root_in_json = true
         | 
| 14 | 
            +
            # end
         | 
| @@ -0,0 +1,23 @@ | |
| 1 | 
            +
            # Files in the config/locales directory are used for internationalization
         | 
| 2 | 
            +
            # and are automatically loaded by Rails. If you want to use locales other
         | 
| 3 | 
            +
            # than English, add the necessary files in this directory.
         | 
| 4 | 
            +
            #
         | 
| 5 | 
            +
            # To use the locales, use `I18n.t`:
         | 
| 6 | 
            +
            #
         | 
| 7 | 
            +
            #     I18n.t 'hello'
         | 
| 8 | 
            +
            #
         | 
| 9 | 
            +
            # In views, this is aliased to just `t`:
         | 
| 10 | 
            +
            #
         | 
| 11 | 
            +
            #     <%= t('hello') %>
         | 
| 12 | 
            +
            #
         | 
| 13 | 
            +
            # To use a different locale, set it with `I18n.locale`:
         | 
| 14 | 
            +
            #
         | 
| 15 | 
            +
            #     I18n.locale = :es
         | 
| 16 | 
            +
            #
         | 
| 17 | 
            +
            # This would use the information in config/locales/es.yml.
         | 
| 18 | 
            +
            #
         | 
| 19 | 
            +
            # To learn more, please read the Rails Internationalization guide
         | 
| 20 | 
            +
            # available at http://guides.rubyonrails.org/i18n.html.
         | 
| 21 | 
            +
             | 
| 22 | 
            +
            en:
         | 
| 23 | 
            +
              hello: "Hello world"
         | 
| @@ -0,0 +1,58 @@ | |
| 1 | 
            +
            Dummy::Application.routes.draw do
         | 
| 2 | 
            +
              resources :articles
         | 
| 3 | 
            +
             | 
| 4 | 
            +
              # The priority is based upon order of creation: first created -> highest priority.
         | 
| 5 | 
            +
              # See how all your routes lay out with "rake routes".
         | 
| 6 | 
            +
             | 
| 7 | 
            +
              # You can have the root of your site routed with "root"
         | 
| 8 | 
            +
              # root 'welcome#index'
         | 
| 9 | 
            +
             | 
| 10 | 
            +
              # Example of regular route:
         | 
| 11 | 
            +
              #   get 'products/:id' => 'catalog#view'
         | 
| 12 | 
            +
             | 
| 13 | 
            +
              # Example of named route that can be invoked with purchase_url(id: product.id)
         | 
| 14 | 
            +
              #   get 'products/:id/purchase' => 'catalog#purchase', as: :purchase
         | 
| 15 | 
            +
             | 
| 16 | 
            +
              # Example resource route (maps HTTP verbs to controller actions automatically):
         | 
| 17 | 
            +
              #   resources :products
         | 
| 18 | 
            +
             | 
| 19 | 
            +
              # Example resource route with options:
         | 
| 20 | 
            +
              #   resources :products do
         | 
| 21 | 
            +
              #     member do
         | 
| 22 | 
            +
              #       get 'short'
         | 
| 23 | 
            +
              #       post 'toggle'
         | 
| 24 | 
            +
              #     end
         | 
| 25 | 
            +
              #
         | 
| 26 | 
            +
              #     collection do
         | 
| 27 | 
            +
              #       get 'sold'
         | 
| 28 | 
            +
              #     end
         | 
| 29 | 
            +
              #   end
         | 
| 30 | 
            +
             | 
| 31 | 
            +
              # Example resource route with sub-resources:
         | 
| 32 | 
            +
              #   resources :products do
         | 
| 33 | 
            +
              #     resources :comments, :sales
         | 
| 34 | 
            +
              #     resource :seller
         | 
| 35 | 
            +
              #   end
         | 
| 36 | 
            +
             | 
| 37 | 
            +
              # Example resource route with more complex sub-resources:
         | 
| 38 | 
            +
              #   resources :products do
         | 
| 39 | 
            +
              #     resources :comments
         | 
| 40 | 
            +
              #     resources :sales do
         | 
| 41 | 
            +
              #       get 'recent', on: :collection
         | 
| 42 | 
            +
              #     end
         | 
| 43 | 
            +
              #   end
         | 
| 44 | 
            +
              
         | 
| 45 | 
            +
              # Example resource route with concerns:
         | 
| 46 | 
            +
              #   concern :toggleable do
         | 
| 47 | 
            +
              #     post 'toggle'
         | 
| 48 | 
            +
              #   end
         | 
| 49 | 
            +
              #   resources :posts, concerns: :toggleable
         | 
| 50 | 
            +
              #   resources :photos, concerns: :toggleable
         | 
| 51 | 
            +
             | 
| 52 | 
            +
              # Example resource route within a namespace:
         | 
| 53 | 
            +
              #   namespace :admin do
         | 
| 54 | 
            +
              #     # Directs /admin/products/* to Admin::ProductsController
         | 
| 55 | 
            +
              #     # (app/controllers/admin/products_controller.rb)
         | 
| 56 | 
            +
              #     resources :products
         | 
| 57 | 
            +
              #   end
         | 
| 58 | 
            +
            end
         | 
| @@ -0,0 +1,24 @@ | |
| 1 | 
            +
            # encoding: UTF-8
         | 
| 2 | 
            +
            # This file is auto-generated from the current state of the database. Instead
         | 
| 3 | 
            +
            # of editing this file, please use the migrations feature of Active Record to
         | 
| 4 | 
            +
            # incrementally modify your database, and then regenerate this schema definition.
         | 
| 5 | 
            +
            #
         | 
| 6 | 
            +
            # Note that this schema.rb definition is the authoritative source for your
         | 
| 7 | 
            +
            # database schema. If you need to create the application database on another
         | 
| 8 | 
            +
            # system, you should be using db:schema:load, not running all the migrations
         | 
| 9 | 
            +
            # from scratch. The latter is a flawed and unsustainable approach (the more migrations
         | 
| 10 | 
            +
            # you'll amass, the slower it'll run and the greater likelihood for issues).
         | 
| 11 | 
            +
            #
         | 
| 12 | 
            +
            # It's strongly recommended that you check this file into your version control system.
         | 
| 13 | 
            +
             | 
| 14 | 
            +
            ActiveRecord::Schema.define(version: 20130801141015) do
         | 
| 15 | 
            +
             | 
| 16 | 
            +
              create_table "articles", force: true do |t|
         | 
| 17 | 
            +
                t.string   "title"
         | 
| 18 | 
            +
                t.text     "body"
         | 
| 19 | 
            +
                t.string   "image"
         | 
| 20 | 
            +
                t.datetime "created_at"
         | 
| 21 | 
            +
                t.datetime "updated_at"
         | 
| 22 | 
            +
              end
         | 
| 23 | 
            +
             | 
| 24 | 
            +
            end
         | 
| @@ -0,0 +1,7 @@ | |
| 1 | 
            +
            # This file should contain all the record creation needed to seed the database with its default values.
         | 
| 2 | 
            +
            # The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).
         | 
| 3 | 
            +
            #
         | 
| 4 | 
            +
            # Examples:
         | 
| 5 | 
            +
            #
         | 
| 6 | 
            +
            #   cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])
         | 
| 7 | 
            +
            #   Mayor.create(name: 'Emanuel', city: cities.first)
         | 
| @@ -0,0 +1,58 @@ | |
| 1 | 
            +
            <!DOCTYPE html>
         | 
| 2 | 
            +
            <html>
         | 
| 3 | 
            +
            <head>
         | 
| 4 | 
            +
              <title>The page you were looking for doesn't exist (404)</title>
         | 
| 5 | 
            +
              <style>
         | 
| 6 | 
            +
              body {
         | 
| 7 | 
            +
                background-color: #EFEFEF;
         | 
| 8 | 
            +
                color: #2E2F30;
         | 
| 9 | 
            +
                text-align: center;
         | 
| 10 | 
            +
                font-family: arial, sans-serif;
         | 
| 11 | 
            +
              }
         | 
| 12 | 
            +
             | 
| 13 | 
            +
              div.dialog {
         | 
| 14 | 
            +
                width: 25em;
         | 
| 15 | 
            +
                margin: 4em auto 0 auto;
         | 
| 16 | 
            +
                border: 1px solid #CCC;
         | 
| 17 | 
            +
                border-right-color: #999;
         | 
| 18 | 
            +
                border-left-color: #999;
         | 
| 19 | 
            +
                border-bottom-color: #BBB;
         | 
| 20 | 
            +
                border-top: #B00100 solid 4px;
         | 
| 21 | 
            +
                border-top-left-radius: 9px;
         | 
| 22 | 
            +
                border-top-right-radius: 9px;
         | 
| 23 | 
            +
                background-color: white;
         | 
| 24 | 
            +
                padding: 7px 4em 0 4em;
         | 
| 25 | 
            +
              }
         | 
| 26 | 
            +
             | 
| 27 | 
            +
              h1 {
         | 
| 28 | 
            +
                font-size: 100%;
         | 
| 29 | 
            +
                color: #730E15;
         | 
| 30 | 
            +
                line-height: 1.5em;
         | 
| 31 | 
            +
              }
         | 
| 32 | 
            +
             | 
| 33 | 
            +
              body > p {
         | 
| 34 | 
            +
                width: 33em;
         | 
| 35 | 
            +
                margin: 0 auto 1em;
         | 
| 36 | 
            +
                padding: 1em 0;
         | 
| 37 | 
            +
                background-color: #F7F7F7;
         | 
| 38 | 
            +
                border: 1px solid #CCC;
         | 
| 39 | 
            +
                border-right-color: #999;
         | 
| 40 | 
            +
                border-bottom-color: #999;
         | 
| 41 | 
            +
                border-bottom-left-radius: 4px;
         | 
| 42 | 
            +
                border-bottom-right-radius: 4px;
         | 
| 43 | 
            +
                border-top-color: #DADADA;
         | 
| 44 | 
            +
                color: #666;
         | 
| 45 | 
            +
                box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
         | 
| 46 | 
            +
              }
         | 
| 47 | 
            +
              </style>
         | 
| 48 | 
            +
            </head>
         | 
| 49 | 
            +
             | 
| 50 | 
            +
            <body>
         | 
| 51 | 
            +
              <!-- This file lives in public/404.html -->
         | 
| 52 | 
            +
              <div class="dialog">
         | 
| 53 | 
            +
                <h1>The page you were looking for doesn't exist.</h1>
         | 
| 54 | 
            +
                <p>You may have mistyped the address or the page may have moved.</p>
         | 
| 55 | 
            +
              </div>
         | 
| 56 | 
            +
              <p>If you are the application owner check the logs for more information.</p>
         | 
| 57 | 
            +
            </body>
         | 
| 58 | 
            +
            </html>
         | 
| @@ -0,0 +1,58 @@ | |
| 1 | 
            +
            <!DOCTYPE html>
         | 
| 2 | 
            +
            <html>
         | 
| 3 | 
            +
            <head>
         | 
| 4 | 
            +
              <title>The change you wanted was rejected (422)</title>
         | 
| 5 | 
            +
              <style>
         | 
| 6 | 
            +
              body {
         | 
| 7 | 
            +
                background-color: #EFEFEF;
         | 
| 8 | 
            +
                color: #2E2F30;
         | 
| 9 | 
            +
                text-align: center;
         | 
| 10 | 
            +
                font-family: arial, sans-serif;
         | 
| 11 | 
            +
              }
         | 
| 12 | 
            +
             | 
| 13 | 
            +
              div.dialog {
         | 
| 14 | 
            +
                width: 25em;
         | 
| 15 | 
            +
                margin: 4em auto 0 auto;
         | 
| 16 | 
            +
                border: 1px solid #CCC;
         | 
| 17 | 
            +
                border-right-color: #999;
         | 
| 18 | 
            +
                border-left-color: #999;
         | 
| 19 | 
            +
                border-bottom-color: #BBB;
         | 
| 20 | 
            +
                border-top: #B00100 solid 4px;
         | 
| 21 | 
            +
                border-top-left-radius: 9px;
         | 
| 22 | 
            +
                border-top-right-radius: 9px;
         | 
| 23 | 
            +
                background-color: white;
         | 
| 24 | 
            +
                padding: 7px 4em 0 4em;
         | 
| 25 | 
            +
              }
         | 
| 26 | 
            +
             | 
| 27 | 
            +
              h1 {
         | 
| 28 | 
            +
                font-size: 100%;
         | 
| 29 | 
            +
                color: #730E15;
         | 
| 30 | 
            +
                line-height: 1.5em;
         | 
| 31 | 
            +
              }
         | 
| 32 | 
            +
             | 
| 33 | 
            +
              body > p {
         | 
| 34 | 
            +
                width: 33em;
         | 
| 35 | 
            +
                margin: 0 auto 1em;
         | 
| 36 | 
            +
                padding: 1em 0;
         | 
| 37 | 
            +
                background-color: #F7F7F7;
         | 
| 38 | 
            +
                border: 1px solid #CCC;
         | 
| 39 | 
            +
                border-right-color: #999;
         | 
| 40 | 
            +
                border-bottom-color: #999;
         | 
| 41 | 
            +
                border-bottom-left-radius: 4px;
         | 
| 42 | 
            +
                border-bottom-right-radius: 4px;
         | 
| 43 | 
            +
                border-top-color: #DADADA;
         | 
| 44 | 
            +
                color: #666;
         | 
| 45 | 
            +
                box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
         | 
| 46 | 
            +
              }
         | 
| 47 | 
            +
              </style>
         | 
| 48 | 
            +
            </head>
         | 
| 49 | 
            +
             | 
| 50 | 
            +
            <body>
         | 
| 51 | 
            +
              <!-- This file lives in public/422.html -->
         | 
| 52 | 
            +
              <div class="dialog">
         | 
| 53 | 
            +
                <h1>The change you wanted was rejected.</h1>
         | 
| 54 | 
            +
                <p>Maybe you tried to change something you didn't have access to.</p>
         | 
| 55 | 
            +
              </div>
         | 
| 56 | 
            +
              <p>If you are the application owner check the logs for more information.</p>
         | 
| 57 | 
            +
            </body>
         | 
| 58 | 
            +
            </html>
         | 
| @@ -0,0 +1,57 @@ | |
| 1 | 
            +
            <!DOCTYPE html>
         | 
| 2 | 
            +
            <html>
         | 
| 3 | 
            +
            <head>
         | 
| 4 | 
            +
              <title>We're sorry, but something went wrong (500)</title>
         | 
| 5 | 
            +
              <style>
         | 
| 6 | 
            +
              body {
         | 
| 7 | 
            +
                background-color: #EFEFEF;
         | 
| 8 | 
            +
                color: #2E2F30;
         | 
| 9 | 
            +
                text-align: center;
         | 
| 10 | 
            +
                font-family: arial, sans-serif;
         | 
| 11 | 
            +
              }
         | 
| 12 | 
            +
             | 
| 13 | 
            +
              div.dialog {
         | 
| 14 | 
            +
                width: 25em;
         | 
| 15 | 
            +
                margin: 4em auto 0 auto;
         | 
| 16 | 
            +
                border: 1px solid #CCC;
         | 
| 17 | 
            +
                border-right-color: #999;
         | 
| 18 | 
            +
                border-left-color: #999;
         | 
| 19 | 
            +
                border-bottom-color: #BBB;
         | 
| 20 | 
            +
                border-top: #B00100 solid 4px;
         | 
| 21 | 
            +
                border-top-left-radius: 9px;
         | 
| 22 | 
            +
                border-top-right-radius: 9px;
         | 
| 23 | 
            +
                background-color: white;
         | 
| 24 | 
            +
                padding: 7px 4em 0 4em;
         | 
| 25 | 
            +
              }
         | 
| 26 | 
            +
             | 
| 27 | 
            +
              h1 {
         | 
| 28 | 
            +
                font-size: 100%;
         | 
| 29 | 
            +
                color: #730E15;
         | 
| 30 | 
            +
                line-height: 1.5em;
         | 
| 31 | 
            +
              }
         | 
| 32 | 
            +
             | 
| 33 | 
            +
              body > p {
         | 
| 34 | 
            +
                width: 33em;
         | 
| 35 | 
            +
                margin: 0 auto 1em;
         | 
| 36 | 
            +
                padding: 1em 0;
         | 
| 37 | 
            +
                background-color: #F7F7F7;
         | 
| 38 | 
            +
                border: 1px solid #CCC;
         | 
| 39 | 
            +
                border-right-color: #999;
         | 
| 40 | 
            +
                border-bottom-color: #999;
         | 
| 41 | 
            +
                border-bottom-left-radius: 4px;
         | 
| 42 | 
            +
                border-bottom-right-radius: 4px;
         | 
| 43 | 
            +
                border-top-color: #DADADA;
         | 
| 44 | 
            +
                color: #666;
         | 
| 45 | 
            +
                box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
         | 
| 46 | 
            +
              }
         | 
| 47 | 
            +
              </style>
         | 
| 48 | 
            +
            </head>
         | 
| 49 | 
            +
             | 
| 50 | 
            +
            <body>
         | 
| 51 | 
            +
              <!-- This file lives in public/500.html -->
         | 
| 52 | 
            +
              <div class="dialog">
         | 
| 53 | 
            +
                <h1>We're sorry, but something went wrong.</h1>
         | 
| 54 | 
            +
              </div>
         | 
| 55 | 
            +
              <p>If you are the application owner check the logs for more information.</p>
         | 
| 56 | 
            +
            </body>
         | 
| 57 | 
            +
            </html>
         | 
| 
            File without changes
         | 
| @@ -0,0 +1,32 @@ | |
| 1 | 
            +
            feature "Upload a file to Dropbox" do
         | 
| 2 | 
            +
              before(:each) do
         | 
| 3 | 
            +
                Article.delete_all
         | 
| 4 | 
            +
              end
         | 
| 5 | 
            +
             | 
| 6 | 
            +
              scenario "Uploading a simple file" do
         | 
| 7 | 
            +
                visit "/articles/new"
         | 
| 8 | 
            +
                Article.count.should eq(0)
         | 
| 9 | 
            +
             | 
| 10 | 
            +
                within("form") do
         | 
| 11 | 
            +
                  fill_in "Title", with: "Hello world!"
         | 
| 12 | 
            +
                  fill_in "Body", with: "Foo bar baz"
         | 
| 13 | 
            +
                  attach_file "Image", File.expand_path('spec/fixtures/ruby.png')
         | 
| 14 | 
            +
             | 
| 15 | 
            +
                  find("input[type='submit']").click
         | 
| 16 | 
            +
                end
         | 
| 17 | 
            +
             | 
| 18 | 
            +
                page.should have_content("Article was successfully created")
         | 
| 19 | 
            +
                Article.count.should eq(1)
         | 
| 20 | 
            +
             | 
| 21 | 
            +
                image_path = Article.last.image.url
         | 
| 22 | 
            +
                thumb_path = Article.last.image.url(:thumbnail)
         | 
| 23 | 
            +
             | 
| 24 | 
            +
                visit image_path
         | 
| 25 | 
            +
                image_path.should match(/foo/)
         | 
| 26 | 
            +
                page.should have_css("img")
         | 
| 27 | 
            +
             | 
| 28 | 
            +
                visit thumb_path
         | 
| 29 | 
            +
                thumb_path.should match(/foo/)
         | 
| 30 | 
            +
                page.should have_css("img")
         | 
| 31 | 
            +
              end
         | 
| 32 | 
            +
            end
         | 
| Binary file | 
    
        data/spec/spec_helper.rb
    ADDED
    
    | @@ -0,0 +1,15 @@ | |
| 1 | 
            +
            ENV["RAILS_ENV"] = "test"
         | 
| 2 | 
            +
            require 'rspec'
         | 
| 3 | 
            +
             | 
| 4 | 
            +
            require 'dummy/config/environment'
         | 
| 5 | 
            +
             | 
| 6 | 
            +
            require 'carrierwave'
         | 
| 7 | 
            +
            require 'carrierwave/dropbox'
         | 
| 8 | 
            +
             | 
| 9 | 
            +
            require 'capybara/rspec'
         | 
| 10 | 
            +
             | 
| 11 | 
            +
            RSpec.configure do |config|
         | 
| 12 | 
            +
              Capybara.app = Dummy::Application
         | 
| 13 | 
            +
              Capybara.current_driver = :selenium
         | 
| 14 | 
            +
              config.order = 'random'
         | 
| 15 | 
            +
            end
         | 
    
        metadata
    ADDED
    
    | @@ -0,0 +1,307 @@ | |
| 1 | 
            +
            --- !ruby/object:Gem::Specification
         | 
| 2 | 
            +
            name: carrierwave-dropbox
         | 
| 3 | 
            +
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            +
              version: 1.0.0
         | 
| 5 | 
            +
            platform: ruby
         | 
| 6 | 
            +
            authors:
         | 
| 7 | 
            +
            - Robin Dupret
         | 
| 8 | 
            +
            autorequire: 
         | 
| 9 | 
            +
            bindir: bin
         | 
| 10 | 
            +
            cert_chain: []
         | 
| 11 | 
            +
            date: 2013-08-02 00:00:00.000000000 Z
         | 
| 12 | 
            +
            dependencies:
         | 
| 13 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 14 | 
            +
              name: carrierwave
         | 
| 15 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 16 | 
            +
                requirements:
         | 
| 17 | 
            +
                - - ~>
         | 
| 18 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 19 | 
            +
                    version: '0.9'
         | 
| 20 | 
            +
              type: :runtime
         | 
| 21 | 
            +
              prerelease: false
         | 
| 22 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 23 | 
            +
                requirements:
         | 
| 24 | 
            +
                - - ~>
         | 
| 25 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 26 | 
            +
                    version: '0.9'
         | 
| 27 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 28 | 
            +
              name: dropbox-sdk
         | 
| 29 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 30 | 
            +
                requirements:
         | 
| 31 | 
            +
                - - ~>
         | 
| 32 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 33 | 
            +
                    version: '1.6'
         | 
| 34 | 
            +
              type: :runtime
         | 
| 35 | 
            +
              prerelease: false
         | 
| 36 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 37 | 
            +
                requirements:
         | 
| 38 | 
            +
                - - ~>
         | 
| 39 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 40 | 
            +
                    version: '1.6'
         | 
| 41 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 42 | 
            +
              name: bundler
         | 
| 43 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 44 | 
            +
                requirements:
         | 
| 45 | 
            +
                - - ~>
         | 
| 46 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 47 | 
            +
                    version: '1.3'
         | 
| 48 | 
            +
              type: :development
         | 
| 49 | 
            +
              prerelease: false
         | 
| 50 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 51 | 
            +
                requirements:
         | 
| 52 | 
            +
                - - ~>
         | 
| 53 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 54 | 
            +
                    version: '1.3'
         | 
| 55 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 56 | 
            +
              name: rake
         | 
| 57 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 58 | 
            +
                requirements:
         | 
| 59 | 
            +
                - - '>='
         | 
| 60 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 61 | 
            +
                    version: '0'
         | 
| 62 | 
            +
              type: :development
         | 
| 63 | 
            +
              prerelease: false
         | 
| 64 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 65 | 
            +
                requirements:
         | 
| 66 | 
            +
                - - '>='
         | 
| 67 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 68 | 
            +
                    version: '0'
         | 
| 69 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 70 | 
            +
              name: capybara
         | 
| 71 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 72 | 
            +
                requirements:
         | 
| 73 | 
            +
                - - ~>
         | 
| 74 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 75 | 
            +
                    version: '2.0'
         | 
| 76 | 
            +
              type: :development
         | 
| 77 | 
            +
              prerelease: false
         | 
| 78 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 79 | 
            +
                requirements:
         | 
| 80 | 
            +
                - - ~>
         | 
| 81 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 82 | 
            +
                    version: '2.0'
         | 
| 83 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 84 | 
            +
              name: rspec
         | 
| 85 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 86 | 
            +
                requirements:
         | 
| 87 | 
            +
                - - ~>
         | 
| 88 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 89 | 
            +
                    version: '2.14'
         | 
| 90 | 
            +
              type: :development
         | 
| 91 | 
            +
              prerelease: false
         | 
| 92 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 93 | 
            +
                requirements:
         | 
| 94 | 
            +
                - - ~>
         | 
| 95 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 96 | 
            +
                    version: '2.14'
         | 
| 97 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 98 | 
            +
              name: sqlite3
         | 
| 99 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 100 | 
            +
                requirements:
         | 
| 101 | 
            +
                - - '>='
         | 
| 102 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 103 | 
            +
                    version: '0'
         | 
| 104 | 
            +
              type: :development
         | 
| 105 | 
            +
              prerelease: false
         | 
| 106 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 107 | 
            +
                requirements:
         | 
| 108 | 
            +
                - - '>='
         | 
| 109 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 110 | 
            +
                    version: '0'
         | 
| 111 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 112 | 
            +
              name: mini_magick
         | 
| 113 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 114 | 
            +
                requirements:
         | 
| 115 | 
            +
                - - '>='
         | 
| 116 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 117 | 
            +
                    version: '0'
         | 
| 118 | 
            +
              type: :development
         | 
| 119 | 
            +
              prerelease: false
         | 
| 120 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 121 | 
            +
                requirements:
         | 
| 122 | 
            +
                - - '>='
         | 
| 123 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 124 | 
            +
                    version: '0'
         | 
| 125 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 126 | 
            +
              name: selenium-webdriver
         | 
| 127 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 128 | 
            +
                requirements:
         | 
| 129 | 
            +
                - - '>='
         | 
| 130 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 131 | 
            +
                    version: '0'
         | 
| 132 | 
            +
              type: :development
         | 
| 133 | 
            +
              prerelease: false
         | 
| 134 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 135 | 
            +
                requirements:
         | 
| 136 | 
            +
                - - '>='
         | 
| 137 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 138 | 
            +
                    version: '0'
         | 
| 139 | 
            +
            - !ruby/object:Gem::Dependency
         | 
| 140 | 
            +
              name: rails
         | 
| 141 | 
            +
              requirement: !ruby/object:Gem::Requirement
         | 
| 142 | 
            +
                requirements:
         | 
| 143 | 
            +
                - - '>='
         | 
| 144 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 145 | 
            +
                    version: 3.2.14
         | 
| 146 | 
            +
                - - <
         | 
| 147 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 148 | 
            +
                    version: '5.0'
         | 
| 149 | 
            +
              type: :development
         | 
| 150 | 
            +
              prerelease: false
         | 
| 151 | 
            +
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 152 | 
            +
                requirements:
         | 
| 153 | 
            +
                - - '>='
         | 
| 154 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 155 | 
            +
                    version: 3.2.14
         | 
| 156 | 
            +
                - - <
         | 
| 157 | 
            +
                  - !ruby/object:Gem::Version
         | 
| 158 | 
            +
                    version: '5.0'
         | 
| 159 | 
            +
            description: CarrierWave storage for Dropbox
         | 
| 160 | 
            +
            email:
         | 
| 161 | 
            +
            - robin.dupret@gmail.com
         | 
| 162 | 
            +
            executables: []
         | 
| 163 | 
            +
            extensions: []
         | 
| 164 | 
            +
            extra_rdoc_files: []
         | 
| 165 | 
            +
            files:
         | 
| 166 | 
            +
            - .gitignore
         | 
| 167 | 
            +
            - .rspec
         | 
| 168 | 
            +
            - Gemfile
         | 
| 169 | 
            +
            - LICENSE
         | 
| 170 | 
            +
            - README.md
         | 
| 171 | 
            +
            - Rakefile
         | 
| 172 | 
            +
            - carrierwave-dropbox.gemspec
         | 
| 173 | 
            +
            - lib/carrierwave/dropbox.rb
         | 
| 174 | 
            +
            - lib/carrierwave/dropbox/authorize.rake
         | 
| 175 | 
            +
            - lib/carrierwave/dropbox/railtie.rb
         | 
| 176 | 
            +
            - lib/carrierwave/dropbox/rake.rb
         | 
| 177 | 
            +
            - lib/carrierwave/dropbox/version.rb
         | 
| 178 | 
            +
            - lib/carrierwave/storage/dropbox.rb
         | 
| 179 | 
            +
            - spec/carrierwave-uploader-base_spec.rb
         | 
| 180 | 
            +
            - spec/dummy/.gitignore
         | 
| 181 | 
            +
            - spec/dummy/Gemfile
         | 
| 182 | 
            +
            - spec/dummy/Rakefile
         | 
| 183 | 
            +
            - spec/dummy/app/controllers/application_controller.rb
         | 
| 184 | 
            +
            - spec/dummy/app/controllers/articles_controller.rb
         | 
| 185 | 
            +
            - spec/dummy/app/controllers/concerns/.keep
         | 
| 186 | 
            +
            - spec/dummy/app/helpers/application_helper.rb
         | 
| 187 | 
            +
            - spec/dummy/app/helpers/articles_helper.rb
         | 
| 188 | 
            +
            - spec/dummy/app/mailers/.keep
         | 
| 189 | 
            +
            - spec/dummy/app/models/.keep
         | 
| 190 | 
            +
            - spec/dummy/app/models/article.rb
         | 
| 191 | 
            +
            - spec/dummy/app/models/concerns/.keep
         | 
| 192 | 
            +
            - spec/dummy/app/uploaders/image_uploader.rb
         | 
| 193 | 
            +
            - spec/dummy/app/views/articles/_form.html.erb
         | 
| 194 | 
            +
            - spec/dummy/app/views/articles/edit.html.erb
         | 
| 195 | 
            +
            - spec/dummy/app/views/articles/index.html.erb
         | 
| 196 | 
            +
            - spec/dummy/app/views/articles/new.html.erb
         | 
| 197 | 
            +
            - spec/dummy/app/views/articles/show.html.erb
         | 
| 198 | 
            +
            - spec/dummy/app/views/layouts/application.html.erb
         | 
| 199 | 
            +
            - spec/dummy/bin/bundle
         | 
| 200 | 
            +
            - spec/dummy/bin/rails
         | 
| 201 | 
            +
            - spec/dummy/bin/rake
         | 
| 202 | 
            +
            - spec/dummy/config.ru
         | 
| 203 | 
            +
            - spec/dummy/config/application.rb
         | 
| 204 | 
            +
            - spec/dummy/config/boot.rb
         | 
| 205 | 
            +
            - spec/dummy/config/database.yml
         | 
| 206 | 
            +
            - spec/dummy/config/environment.rb
         | 
| 207 | 
            +
            - spec/dummy/config/environments/development.rb
         | 
| 208 | 
            +
            - spec/dummy/config/environments/production.rb
         | 
| 209 | 
            +
            - spec/dummy/config/environments/test.rb
         | 
| 210 | 
            +
            - spec/dummy/config/initializers/backtrace_silencers.rb
         | 
| 211 | 
            +
            - spec/dummy/config/initializers/carrierwave.rb
         | 
| 212 | 
            +
            - spec/dummy/config/initializers/filter_parameter_logging.rb
         | 
| 213 | 
            +
            - spec/dummy/config/initializers/inflections.rb
         | 
| 214 | 
            +
            - spec/dummy/config/initializers/mime_types.rb
         | 
| 215 | 
            +
            - spec/dummy/config/initializers/secret_token.rb
         | 
| 216 | 
            +
            - spec/dummy/config/initializers/session_store.rb
         | 
| 217 | 
            +
            - spec/dummy/config/initializers/wrap_parameters.rb
         | 
| 218 | 
            +
            - spec/dummy/config/locales/en.yml
         | 
| 219 | 
            +
            - spec/dummy/config/routes.rb
         | 
| 220 | 
            +
            - spec/dummy/db/migrate/20130801141015_create_articles.rb
         | 
| 221 | 
            +
            - spec/dummy/db/schema.rb
         | 
| 222 | 
            +
            - spec/dummy/db/seeds.rb
         | 
| 223 | 
            +
            - spec/dummy/public/404.html
         | 
| 224 | 
            +
            - spec/dummy/public/422.html
         | 
| 225 | 
            +
            - spec/dummy/public/500.html
         | 
| 226 | 
            +
            - spec/dummy/public/favicon.ico
         | 
| 227 | 
            +
            - spec/dummy/public/robots.txt
         | 
| 228 | 
            +
            - spec/features/upload_file_spec.rb
         | 
| 229 | 
            +
            - spec/fixtures/ruby.png
         | 
| 230 | 
            +
            - spec/spec_helper.rb
         | 
| 231 | 
            +
            homepage: https://github.com/robin850/carrierwave-dropbox
         | 
| 232 | 
            +
            licenses:
         | 
| 233 | 
            +
            - MIT
         | 
| 234 | 
            +
            metadata: {}
         | 
| 235 | 
            +
            post_install_message: 
         | 
| 236 | 
            +
            rdoc_options: []
         | 
| 237 | 
            +
            require_paths:
         | 
| 238 | 
            +
            - lib
         | 
| 239 | 
            +
            required_ruby_version: !ruby/object:Gem::Requirement
         | 
| 240 | 
            +
              requirements:
         | 
| 241 | 
            +
              - - '>='
         | 
| 242 | 
            +
                - !ruby/object:Gem::Version
         | 
| 243 | 
            +
                  version: '0'
         | 
| 244 | 
            +
            required_rubygems_version: !ruby/object:Gem::Requirement
         | 
| 245 | 
            +
              requirements:
         | 
| 246 | 
            +
              - - '>='
         | 
| 247 | 
            +
                - !ruby/object:Gem::Version
         | 
| 248 | 
            +
                  version: '0'
         | 
| 249 | 
            +
            requirements: []
         | 
| 250 | 
            +
            rubyforge_project: 
         | 
| 251 | 
            +
            rubygems_version: 2.0.3
         | 
| 252 | 
            +
            signing_key: 
         | 
| 253 | 
            +
            specification_version: 4
         | 
| 254 | 
            +
            summary: Dropbox integration for CarrierWave
         | 
| 255 | 
            +
            test_files:
         | 
| 256 | 
            +
            - spec/carrierwave-uploader-base_spec.rb
         | 
| 257 | 
            +
            - spec/dummy/.gitignore
         | 
| 258 | 
            +
            - spec/dummy/Gemfile
         | 
| 259 | 
            +
            - spec/dummy/Rakefile
         | 
| 260 | 
            +
            - spec/dummy/app/controllers/application_controller.rb
         | 
| 261 | 
            +
            - spec/dummy/app/controllers/articles_controller.rb
         | 
| 262 | 
            +
            - spec/dummy/app/controllers/concerns/.keep
         | 
| 263 | 
            +
            - spec/dummy/app/helpers/application_helper.rb
         | 
| 264 | 
            +
            - spec/dummy/app/helpers/articles_helper.rb
         | 
| 265 | 
            +
            - spec/dummy/app/mailers/.keep
         | 
| 266 | 
            +
            - spec/dummy/app/models/.keep
         | 
| 267 | 
            +
            - spec/dummy/app/models/article.rb
         | 
| 268 | 
            +
            - spec/dummy/app/models/concerns/.keep
         | 
| 269 | 
            +
            - spec/dummy/app/uploaders/image_uploader.rb
         | 
| 270 | 
            +
            - spec/dummy/app/views/articles/_form.html.erb
         | 
| 271 | 
            +
            - spec/dummy/app/views/articles/edit.html.erb
         | 
| 272 | 
            +
            - spec/dummy/app/views/articles/index.html.erb
         | 
| 273 | 
            +
            - spec/dummy/app/views/articles/new.html.erb
         | 
| 274 | 
            +
            - spec/dummy/app/views/articles/show.html.erb
         | 
| 275 | 
            +
            - spec/dummy/app/views/layouts/application.html.erb
         | 
| 276 | 
            +
            - spec/dummy/bin/bundle
         | 
| 277 | 
            +
            - spec/dummy/bin/rails
         | 
| 278 | 
            +
            - spec/dummy/bin/rake
         | 
| 279 | 
            +
            - spec/dummy/config.ru
         | 
| 280 | 
            +
            - spec/dummy/config/application.rb
         | 
| 281 | 
            +
            - spec/dummy/config/boot.rb
         | 
| 282 | 
            +
            - spec/dummy/config/database.yml
         | 
| 283 | 
            +
            - spec/dummy/config/environment.rb
         | 
| 284 | 
            +
            - spec/dummy/config/environments/development.rb
         | 
| 285 | 
            +
            - spec/dummy/config/environments/production.rb
         | 
| 286 | 
            +
            - spec/dummy/config/environments/test.rb
         | 
| 287 | 
            +
            - spec/dummy/config/initializers/backtrace_silencers.rb
         | 
| 288 | 
            +
            - spec/dummy/config/initializers/carrierwave.rb
         | 
| 289 | 
            +
            - spec/dummy/config/initializers/filter_parameter_logging.rb
         | 
| 290 | 
            +
            - spec/dummy/config/initializers/inflections.rb
         | 
| 291 | 
            +
            - spec/dummy/config/initializers/mime_types.rb
         | 
| 292 | 
            +
            - spec/dummy/config/initializers/secret_token.rb
         | 
| 293 | 
            +
            - spec/dummy/config/initializers/session_store.rb
         | 
| 294 | 
            +
            - spec/dummy/config/initializers/wrap_parameters.rb
         | 
| 295 | 
            +
            - spec/dummy/config/locales/en.yml
         | 
| 296 | 
            +
            - spec/dummy/config/routes.rb
         | 
| 297 | 
            +
            - spec/dummy/db/migrate/20130801141015_create_articles.rb
         | 
| 298 | 
            +
            - spec/dummy/db/schema.rb
         | 
| 299 | 
            +
            - spec/dummy/db/seeds.rb
         | 
| 300 | 
            +
            - spec/dummy/public/404.html
         | 
| 301 | 
            +
            - spec/dummy/public/422.html
         | 
| 302 | 
            +
            - spec/dummy/public/500.html
         | 
| 303 | 
            +
            - spec/dummy/public/favicon.ico
         | 
| 304 | 
            +
            - spec/dummy/public/robots.txt
         | 
| 305 | 
            +
            - spec/features/upload_file_spec.rb
         | 
| 306 | 
            +
            - spec/fixtures/ruby.png
         | 
| 307 | 
            +
            - spec/spec_helper.rb
         |