padrino-admin 0.14.0.rc1 → 0.14.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9f5fe8b0d4121898b6e3408184bde80a47e5ada5
|
4
|
+
data.tar.gz: fe7f50ed5937b673a60c9bcd46dd29c35da11e5c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d6bdaad9e6d002dbb121d69e33995bf9f715d7aaec4f77ea0690edf9985e38c836d28a4828f69fe29b2b1e0aea27d3d7e084b845f69c302bf026c2357837e3ec
|
7
|
+
data.tar.gz: 6db2c8630a4b078a2f65ca338fc9b1205d4aa53ef2688cc073d1d817b675cae84fe8cee718713b8aa2c275bd81b285a340af0742d49e23d02cd2430ba616b77a
|
@@ -12,7 +12,7 @@ module Padrino
|
|
12
12
|
#
|
13
13
|
def registered(app)
|
14
14
|
app.register Padrino::Admin unless app.extensions.include?(Padrino::Admin)
|
15
|
-
app.set :session_id, "_padrino_#{
|
15
|
+
app.set :session_id, "_padrino_#{Padrino.env}_#{app.app_name}" unless app.respond_to?(:session_id)
|
16
16
|
app.set :admin_model, 'Account' unless app.respond_to?(:admin_model)
|
17
17
|
app.helpers Padrino::Admin::Helpers::AuthenticationHelpers
|
18
18
|
app.helpers Padrino::Admin::Helpers::ViewHelpers
|
@@ -49,7 +49,7 @@ module Padrino
|
|
49
49
|
|
50
50
|
tmp_ext = options[:renderer] || fetch_component_choice(:renderer)
|
51
51
|
unless supported_ext.include?(tmp_ext.to_sym)
|
52
|
-
say "<= You are using '#{tmp_ext}' and for admin we only support '#{supported_ext.join(', ')}'. Please use #{supported_ext.map { |ext| '-e ' + ext }.join(' or ')}", :yellow
|
52
|
+
say "<= You are using '#{tmp_ext}' and for admin we only support '#{supported_ext.join(', ')}'. Please use #{supported_ext.map { |ext| '-e ' + ext.to_s }.join(' or ')}", :yellow
|
53
53
|
raise SystemExit
|
54
54
|
end
|
55
55
|
|
@@ -9,21 +9,20 @@ describe "AdminApplication" do
|
|
9
9
|
describe "session id setting" do
|
10
10
|
it "should provide it if it doesn't exist" do
|
11
11
|
mock_app do
|
12
|
+
set :app_name, 'session_id_tester'
|
12
13
|
register Padrino::Admin::AccessControl
|
13
14
|
end
|
14
15
|
|
15
|
-
assert_equal
|
16
|
+
assert_equal "_padrino_test_session_id_tester", @app.session_id
|
16
17
|
end
|
17
18
|
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
# assert_equal @app.session_id, "foo"
|
26
|
-
# end
|
19
|
+
it "should preserve it if it already existed" do
|
20
|
+
mock_app do
|
21
|
+
set :session_id, "foo"
|
22
|
+
register Padrino::Admin::AccessControl
|
23
|
+
end
|
24
|
+
assert_equal "foo", @app.session_id
|
25
|
+
end
|
27
26
|
end
|
28
27
|
|
29
28
|
it 'should require correctly login' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: padrino-admin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.14.0.
|
4
|
+
version: 0.14.0.rc2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Padrino Team
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2017-01-19 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: padrino-core
|
@@ -19,28 +19,28 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - '='
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 0.14.0.
|
22
|
+
version: 0.14.0.rc2
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - '='
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 0.14.0.
|
29
|
+
version: 0.14.0.rc2
|
30
30
|
- !ruby/object:Gem::Dependency
|
31
31
|
name: padrino-helpers
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|
33
33
|
requirements:
|
34
34
|
- - '='
|
35
35
|
- !ruby/object:Gem::Version
|
36
|
-
version: 0.14.0.
|
36
|
+
version: 0.14.0.rc2
|
37
37
|
type: :runtime
|
38
38
|
prerelease: false
|
39
39
|
version_requirements: !ruby/object:Gem::Requirement
|
40
40
|
requirements:
|
41
41
|
- - '='
|
42
42
|
- !ruby/object:Gem::Version
|
43
|
-
version: 0.14.0.
|
43
|
+
version: 0.14.0.rc2
|
44
44
|
- !ruby/object:Gem::Dependency
|
45
45
|
name: therubyracer
|
46
46
|
requirement: !ruby/object:Gem::Requirement
|