omniauth-identity 2.0.0 → 3.0.4

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.
data/Rakefile DELETED
@@ -1,9 +0,0 @@
1
- require 'bundler'
2
- Bundler::GemHelper.install_tasks
3
-
4
- require 'rspec/core/rake_task'
5
- desc "Run specs."
6
- RSpec::Core::RakeTask.new(:spec)
7
-
8
- task :default => :spec
9
- task :test => :spec
@@ -1,32 +0,0 @@
1
- require 'dm-core'
2
- require 'dm-validations'
3
-
4
- module OmniAuth
5
- module Identity
6
- module Models
7
- module DataMapper
8
- def self.included(base)
9
- base.class_eval do
10
- include OmniAuth::Identity::Model
11
- include OmniAuth::Identity::SecurePassword
12
-
13
- # http://api.rubyonrails.org/classes/ActiveRecord/Persistence.html#method-i-persisted-3F
14
- # http://rubydoc.info/github/mongoid/mongoid/master/Mongoid/State#persisted%3F-instance_method
15
- alias persisted? valid?
16
-
17
- has_secure_password
18
-
19
- def self.auth_key=(key)
20
- super
21
- validates_uniqueness_of :key
22
- end
23
-
24
- def self.locate(search_hash)
25
- all(search_hash).first
26
- end
27
- end
28
- end
29
- end # DataMapper
30
- end
31
- end
32
- end
@@ -1,32 +0,0 @@
1
- # -*- encoding: utf-8 -*-
2
- require File.dirname(__FILE__) + '/lib/omniauth-identity/version'
3
-
4
- Gem::Specification.new do |gem|
5
- gem.add_runtime_dependency 'omniauth'
6
- gem.add_runtime_dependency 'bcrypt'
7
-
8
- gem.add_development_dependency 'maruku'
9
- gem.add_development_dependency 'simplecov'
10
- gem.add_development_dependency 'rack-test'
11
- gem.add_development_dependency 'rake'
12
- gem.add_development_dependency 'rspec', '~> 3'
13
- gem.add_development_dependency 'activerecord'
14
- gem.add_development_dependency 'mongoid'
15
- gem.add_development_dependency 'datamapper'
16
- gem.add_development_dependency 'bson_ext'
17
- gem.add_development_dependency 'byebug'
18
- gem.add_development_dependency 'couch_potato'
19
-
20
- gem.name = 'omniauth-identity'
21
- gem.version = OmniAuth::Identity::VERSION
22
- gem.description = %q{Internal authentication handlers for OmniAuth.}
23
- gem.summary = gem.description
24
- gem.homepage = 'http://github.com/omniauth/omniauth-identity'
25
- gem.authors = ['Andrew Roberts', 'Michael Bleigh']
26
- gem.license = 'MIT'
27
- gem.executables = `git ls-files -- bin/*`.split("\n").map{|f| File.basename(f)}
28
- gem.files = `git ls-files`.split("\n")
29
- gem.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
30
- gem.require_paths = ['lib']
31
- gem.required_rubygems_version = Gem::Requirement.new('>= 1.3.6') if gem.respond_to? :required_rubygems_version=
32
- end
@@ -1,24 +0,0 @@
1
- describe(OmniAuth::Identity::Models::DataMapper, :db => true) do
2
- class DataMapperTestIdentity
3
- include DataMapper::Resource
4
- include OmniAuth::Identity::Models::DataMapper
5
-
6
- property :id, Serial
7
- auth_key :ham_sandwich
8
- end
9
-
10
-
11
- before :all do
12
- DataMapper.finalize
13
- @resource = DataMapperTestIdentity.new
14
- end
15
-
16
- describe 'model', type: :model do
17
- subject { DataMapperTestIdentity }
18
-
19
- it 'should delegate locate to the all query method' do
20
- allow(subject).to receive(:all).with('ham_sandwich' => 'open faced', 'category' => 'sandwiches').and_return(['wakka'])
21
- expect(subject.locate('ham_sandwich' => 'open faced', 'category' => 'sandwiches')).to eq('wakka')
22
- end
23
- end
24
- end