Sha256: bcf176240361c11f119f94721d11caa7e33ca8c5044197ccb9bf28b3d0dc6f88

Contents?: true

Size: 378 Bytes

Versions: 20

Compression:

Stored size: 378 Bytes

Contents

module RSpecCandy
  module Helpers
    module Rails
      module PreventStorage

        def prevent_storage
          errors.stub :empty? => false
        end

        def keep_invalid!
          warn 'keep_invalid! is deprecated. Use prevent_storage instead.'
          prevent_storage
        end

        ActiveRecord::Base.send(:include, self)

      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
rspec_candy-0.5.1 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.5.0 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.4.1 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.4.0 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.3.1 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.3.0 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.10 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.9 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.8 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.7 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.6 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.5 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.4 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.3 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.2 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.1 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.2.0 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.1.2 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.1.1 lib/rspec_candy/helpers/rails/prevent_storage.rb
rspec_candy-0.1.0 lib/rspec_candy/helpers/rails/prevent_storage.rb