simple_auth 2.0.2 → 2.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/lib/simple_auth/compat/active_record.rb +1 -4
- data/lib/simple_auth/version.rb +1 -1
- data/spec/simple_auth/compat_spec.rb +7 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c7f989033172d408087d921e6b817deb6a797d86
|
4
|
+
data.tar.gz: 17baff56afe96566e89a03f86c762ca94dc7c273
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bdbbac966ea1a128444781e0e024d61b84116f97eed31e35b1ff34080f025ee67357973f0c6d9177b8783e912dfbe120c747ac576dd6b352cddcc9143029165b
|
7
|
+
data.tar.gz: 7b466f1714756cb0925786814e6e1c40f59c14e715e02b096476a7e51f4683b7b1ebd6742357aa2ab23e2f35dbc6a1f0cbb622ceaeb081fba621b2e1cfc760d7
|
data/CHANGELOG.md
CHANGED
@@ -17,10 +17,7 @@ module SimpleAuth
|
|
17
17
|
module InstanceMethods
|
18
18
|
def password=(password)
|
19
19
|
super SimpleAuth::Config.crypter.call(password, password_salt)
|
20
|
-
|
21
|
-
|
22
|
-
def password_confirmation=(password)
|
23
|
-
super SimpleAuth::Config.crypter.call(password, password_salt)
|
20
|
+
@password = password
|
24
21
|
end
|
25
22
|
|
26
23
|
def authenticate(password)
|
data/lib/simple_auth/version.rb
CHANGED
@@ -10,7 +10,6 @@ describe SimpleAuth, "compatibility mode" do
|
|
10
10
|
after :all do
|
11
11
|
mod = SimpleAuth::ActiveRecord::InstanceMethods
|
12
12
|
mod.send :remove_method, :password=
|
13
|
-
mod.send :remove_method, :password_confirmation=
|
14
13
|
mod.send :remove_method, :authenticate
|
15
14
|
end
|
16
15
|
|
@@ -34,8 +33,13 @@ describe SimpleAuth, "compatibility mode" do
|
|
34
33
|
expect(customer.password_digest).to be_present
|
35
34
|
end
|
36
35
|
|
37
|
-
it "
|
36
|
+
it "sets password" do
|
38
37
|
customer = Customer.create(password: "test", password_confirmation: "test")
|
39
|
-
expect(customer.
|
38
|
+
expect(customer.password).to eql("test")
|
39
|
+
end
|
40
|
+
|
41
|
+
it "sets password confirmation" do
|
42
|
+
customer = Customer.create(password: "test", password_confirmation: "test")
|
43
|
+
expect(customer.password_confirmation).to eql("test")
|
40
44
|
end
|
41
45
|
end
|