iam 0.0.3

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.
Files changed (74) hide show
  1. data/Gemfile +12 -0
  2. data/README.md +4 -0
  3. data/Rakefile +13 -0
  4. data/config/routes.rb +3 -0
  5. data/lib/generators/iam/initializer_generator.rb +15 -0
  6. data/lib/generators/templates/iam.rb +5 -0
  7. data/lib/iam.rb +3 -0
  8. data/lib/iam/configuration.rb +22 -0
  9. data/lib/iam/engine.rb +4 -0
  10. data/lib/iam/version.rb +3 -0
  11. data/spec/rails_app/Rakefile +7 -0
  12. data/spec/rails_app/app/assets/images/rails.png +0 -0
  13. data/spec/rails_app/app/assets/javascripts/application.js +15 -0
  14. data/spec/rails_app/app/assets/stylesheets/application.css +14 -0
  15. data/spec/rails_app/app/controllers/application_controller.rb +3 -0
  16. data/spec/rails_app/app/controllers/pages_controller.rb +4 -0
  17. data/spec/rails_app/app/helpers/application_helper.rb +2 -0
  18. data/spec/rails_app/app/models/role.rb +5 -0
  19. data/spec/rails_app/app/models/user.rb +13 -0
  20. data/spec/rails_app/app/views/layouts/application.html.erb +15 -0
  21. data/spec/rails_app/app/views/pages/index.html.erb +1 -0
  22. data/spec/rails_app/config.ru +4 -0
  23. data/spec/rails_app/config/application.rb +62 -0
  24. data/spec/rails_app/config/boot.rb +6 -0
  25. data/spec/rails_app/config/database.yml +25 -0
  26. data/spec/rails_app/config/environment.rb +5 -0
  27. data/spec/rails_app/config/environments/development.rb +37 -0
  28. data/spec/rails_app/config/environments/production.rb +67 -0
  29. data/spec/rails_app/config/environments/test.rb +37 -0
  30. data/spec/rails_app/config/initializers/backtrace_silencers.rb +7 -0
  31. data/spec/rails_app/config/initializers/devise.rb +232 -0
  32. data/spec/rails_app/config/initializers/inflections.rb +15 -0
  33. data/spec/rails_app/config/initializers/mime_types.rb +5 -0
  34. data/spec/rails_app/config/initializers/secret_token.rb +7 -0
  35. data/spec/rails_app/config/initializers/session_store.rb +8 -0
  36. data/spec/rails_app/config/initializers/wrap_parameters.rb +14 -0
  37. data/spec/rails_app/config/locales/devise.en.yml +58 -0
  38. data/spec/rails_app/config/locales/en.yml +5 -0
  39. data/spec/rails_app/config/routes.rb +61 -0
  40. data/spec/rails_app/db/development.sqlite3 +0 -0
  41. data/spec/rails_app/db/migrate/20121202072519_create_role.rb +7 -0
  42. data/spec/rails_app/db/migrate/20121202072527_create_user.rb +8 -0
  43. data/spec/rails_app/db/migrate/20121202131821_add_devise_to_users.rb +53 -0
  44. data/spec/rails_app/db/schema.rb +38 -0
  45. data/spec/rails_app/db/seeds.rb +7 -0
  46. data/spec/rails_app/db/test.sqlite3 +0 -0
  47. data/spec/rails_app/log/development.log +18702 -0
  48. data/spec/rails_app/public/404.html +26 -0
  49. data/spec/rails_app/public/422.html +26 -0
  50. data/spec/rails_app/public/500.html +25 -0
  51. data/spec/rails_app/public/favicon.ico +0 -0
  52. data/spec/rails_app/public/robots.txt +5 -0
  53. data/spec/rails_app/script/rails +6 -0
  54. data/spec/rails_app/tmp/cache/assets/C84/240/sprockets%2F90159895e983014634c35c3aa0b8ba69 +0 -0
  55. data/spec/rails_app/tmp/cache/assets/CB4/480/sprockets%2F98f3b0197247ae392ee2a0ed56181177 +0 -0
  56. data/spec/rails_app/tmp/cache/assets/CC5/EB0/sprockets%2F940a62ef7993c65b7208eba436378d79 +0 -0
  57. data/spec/rails_app/tmp/cache/assets/CD8/370/sprockets%2F357970feca3ac29060c1e3861e2c0953 +0 -0
  58. data/spec/rails_app/tmp/cache/assets/CE0/ED0/sprockets%2Faffa2b71029862880913b9ec3673e1a5 +0 -0
  59. data/spec/rails_app/tmp/cache/assets/CEC/2C0/sprockets%2F9fe616d3392264856bed8f74a40dd433 +0 -0
  60. data/spec/rails_app/tmp/cache/assets/D31/3D0/sprockets%2Fc14c7515af27310e9bb3e2de009652cf +0 -0
  61. data/spec/rails_app/tmp/cache/assets/D32/A10/sprockets%2F13fe41fee1fe35b49d145bcc06610705 +0 -0
  62. data/spec/rails_app/tmp/cache/assets/D33/BA0/sprockets%2F3c51400d380204f5c9ff0e9d1bc6c19d +0 -0
  63. data/spec/rails_app/tmp/cache/assets/D41/4A0/sprockets%2Fa1d77c19837e94fade9c36f084c0a122 +0 -0
  64. data/spec/rails_app/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655 +0 -0
  65. data/spec/rails_app/tmp/cache/assets/D5A/EA0/sprockets%2Fd771ace226fc8215a3572e0aa35bb0d6 +0 -0
  66. data/spec/rails_app/tmp/cache/assets/D64/740/sprockets%2Ff117cb3b1bafa837b5741ac8553525df +0 -0
  67. data/spec/rails_app/tmp/cache/assets/DA3/420/sprockets%2F487ada14f243cc253ce98bea5ad559e7 +0 -0
  68. data/spec/rails_app/tmp/cache/assets/DBF/B80/sprockets%2Fd2a79d7ae86da898bfe285ca39e9168f +0 -0
  69. data/spec/rails_app/tmp/cache/assets/DDC/400/sprockets%2Fcffd775d018f68ce5dba1ee0d951a994 +0 -0
  70. data/spec/rails_app/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af +0 -0
  71. data/spec/rails_app/tmp/pids/server.pid +1 -0
  72. data/spec/spec_helper.rb +19 -0
  73. data/spec/support/database_cleaner.rb +13 -0
  74. metadata +215 -0
@@ -0,0 +1,26 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The page you were looking for doesn't exist (404)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/404.html -->
21
+ <div class="dialog">
22
+ <h1>The page you were looking for doesn't exist.</h1>
23
+ <p>You may have mistyped the address or the page may have moved.</p>
24
+ </div>
25
+ </body>
26
+ </html>
@@ -0,0 +1,26 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The change you wanted was rejected (422)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/422.html -->
21
+ <div class="dialog">
22
+ <h1>The change you wanted was rejected.</h1>
23
+ <p>Maybe you tried to change something you didn't have access to.</p>
24
+ </div>
25
+ </body>
26
+ </html>
@@ -0,0 +1,25 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>We're sorry, but something went wrong (500)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/500.html -->
21
+ <div class="dialog">
22
+ <h1>We're sorry, but something went wrong.</h1>
23
+ </div>
24
+ </body>
25
+ </html>
File without changes
@@ -0,0 +1,5 @@
1
+ # See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file
2
+ #
3
+ # To ban all spiders from the entire site uncomment the next two lines:
4
+ # User-Agent: *
5
+ # Disallow: /
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env ruby
2
+ # This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
3
+
4
+ APP_PATH = File.expand_path('../../config/application', __FILE__)
5
+ require File.expand_path('../../config/boot', __FILE__)
6
+ require 'rails/commands'
@@ -0,0 +1 @@
1
+ 16448
@@ -0,0 +1,19 @@
1
+ ENV['RAILS_ENV'] = 'test'
2
+
3
+ # Require test Rails app
4
+ require File.expand_path("../../spec/rails_app/config/environment", __FILE__)
5
+
6
+ require 'database_cleaner'
7
+ require 'rspec/rails'
8
+ require 'rspec/autorun'
9
+
10
+ # Requires supporting ruby files with custom matchers and macros, etc,
11
+ # in spec/support/ and its subdirectories.
12
+ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
13
+
14
+ RSpec.configure do |config|
15
+ # If true, the base class of anonymous controllers will be inferred
16
+ # automatically. This will be the default behavior in future versions of
17
+ # rspec-rails.
18
+ config.infer_base_class_for_anonymous_controllers = false
19
+ end
@@ -0,0 +1,13 @@
1
+ DatabaseCleaner[:active_record].strategy = :transaction if defined? ActiveRecord
2
+
3
+ RSpec.configure do |config|
4
+ config.before :suite do
5
+ DatabaseCleaner.clean_with :truncation
6
+ end
7
+ config.before :each do
8
+ DatabaseCleaner.start
9
+ end
10
+ config.after :each do
11
+ DatabaseCleaner.clean
12
+ end
13
+ end
metadata ADDED
@@ -0,0 +1,215 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: iam
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.3
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Yury Kaliada
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2012-12-02 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: activesupport
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
21
+ version: '3.1'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ version: '3.1'
30
+ - !ruby/object:Gem::Dependency
31
+ name: coffee-rails
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ~>
36
+ - !ruby/object:Gem::Version
37
+ version: 3.2.1
38
+ type: :runtime
39
+ prerelease: false
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ~>
44
+ - !ruby/object:Gem::Version
45
+ version: 3.2.1
46
+ - !ruby/object:Gem::Dependency
47
+ name: sass
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :runtime
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ - !ruby/object:Gem::Dependency
63
+ name: devise
64
+ requirement: !ruby/object:Gem::Requirement
65
+ none: false
66
+ requirements:
67
+ - - ! '>='
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ type: :runtime
71
+ prerelease: false
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
78
+ - !ruby/object:Gem::Dependency
79
+ name: rails
80
+ requirement: !ruby/object:Gem::Requirement
81
+ none: false
82
+ requirements:
83
+ - - ~>
84
+ - !ruby/object:Gem::Version
85
+ version: '3.1'
86
+ type: :development
87
+ prerelease: false
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ~>
92
+ - !ruby/object:Gem::Version
93
+ version: '3.1'
94
+ - !ruby/object:Gem::Dependency
95
+ name: rspec-rails
96
+ requirement: !ruby/object:Gem::Requirement
97
+ none: false
98
+ requirements:
99
+ - - ~>
100
+ - !ruby/object:Gem::Version
101
+ version: '2.10'
102
+ type: :development
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ~>
108
+ - !ruby/object:Gem::Version
109
+ version: '2.10'
110
+ description: Simple account switcher for Rails that automatically retrieves a few
111
+ user accounts for each role and provides single-click login feature.
112
+ email: fut.wrk@gmail.com
113
+ executables: []
114
+ extensions: []
115
+ extra_rdoc_files: []
116
+ files:
117
+ - lib/iam.rb
118
+ - lib/iam/version.rb
119
+ - lib/iam/configuration.rb
120
+ - lib/iam/engine.rb
121
+ - lib/generators/templates/iam.rb
122
+ - lib/generators/iam/initializer_generator.rb
123
+ - config/routes.rb
124
+ - spec/spec_helper.rb
125
+ - spec/support/database_cleaner.rb
126
+ - spec/rails_app/app/controllers/application_controller.rb
127
+ - spec/rails_app/app/controllers/pages_controller.rb
128
+ - spec/rails_app/app/models/role.rb
129
+ - spec/rails_app/app/models/user.rb
130
+ - spec/rails_app/app/assets/images/rails.png
131
+ - spec/rails_app/app/assets/stylesheets/application.css
132
+ - spec/rails_app/app/assets/javascripts/application.js
133
+ - spec/rails_app/app/helpers/application_helper.rb
134
+ - spec/rails_app/app/views/pages/index.html.erb
135
+ - spec/rails_app/app/views/layouts/application.html.erb
136
+ - spec/rails_app/log/development.log
137
+ - spec/rails_app/Rakefile
138
+ - spec/rails_app/db/development.sqlite3
139
+ - spec/rails_app/db/schema.rb
140
+ - spec/rails_app/db/test.sqlite3
141
+ - spec/rails_app/db/migrate/20121202072527_create_user.rb
142
+ - spec/rails_app/db/migrate/20121202131821_add_devise_to_users.rb
143
+ - spec/rails_app/db/migrate/20121202072519_create_role.rb
144
+ - spec/rails_app/db/seeds.rb
145
+ - spec/rails_app/public/robots.txt
146
+ - spec/rails_app/public/favicon.ico
147
+ - spec/rails_app/public/422.html
148
+ - spec/rails_app/public/500.html
149
+ - spec/rails_app/public/404.html
150
+ - spec/rails_app/config/routes.rb
151
+ - spec/rails_app/config/environment.rb
152
+ - spec/rails_app/config/database.yml
153
+ - spec/rails_app/config/environments/production.rb
154
+ - spec/rails_app/config/environments/development.rb
155
+ - spec/rails_app/config/environments/test.rb
156
+ - spec/rails_app/config/initializers/devise.rb
157
+ - spec/rails_app/config/initializers/inflections.rb
158
+ - spec/rails_app/config/initializers/wrap_parameters.rb
159
+ - spec/rails_app/config/initializers/mime_types.rb
160
+ - spec/rails_app/config/initializers/backtrace_silencers.rb
161
+ - spec/rails_app/config/initializers/session_store.rb
162
+ - spec/rails_app/config/initializers/secret_token.rb
163
+ - spec/rails_app/config/locales/devise.en.yml
164
+ - spec/rails_app/config/locales/en.yml
165
+ - spec/rails_app/config/application.rb
166
+ - spec/rails_app/config/boot.rb
167
+ - spec/rails_app/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af
168
+ - spec/rails_app/tmp/cache/assets/D31/3D0/sprockets%2Fc14c7515af27310e9bb3e2de009652cf
169
+ - spec/rails_app/tmp/cache/assets/DA3/420/sprockets%2F487ada14f243cc253ce98bea5ad559e7
170
+ - spec/rails_app/tmp/cache/assets/D32/A10/sprockets%2F13fe41fee1fe35b49d145bcc06610705
171
+ - spec/rails_app/tmp/cache/assets/D41/4A0/sprockets%2Fa1d77c19837e94fade9c36f084c0a122
172
+ - spec/rails_app/tmp/cache/assets/D64/740/sprockets%2Ff117cb3b1bafa837b5741ac8553525df
173
+ - spec/rails_app/tmp/cache/assets/D33/BA0/sprockets%2F3c51400d380204f5c9ff0e9d1bc6c19d
174
+ - spec/rails_app/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655
175
+ - spec/rails_app/tmp/cache/assets/C84/240/sprockets%2F90159895e983014634c35c3aa0b8ba69
176
+ - spec/rails_app/tmp/cache/assets/D5A/EA0/sprockets%2Fd771ace226fc8215a3572e0aa35bb0d6
177
+ - spec/rails_app/tmp/cache/assets/CEC/2C0/sprockets%2F9fe616d3392264856bed8f74a40dd433
178
+ - spec/rails_app/tmp/cache/assets/CD8/370/sprockets%2F357970feca3ac29060c1e3861e2c0953
179
+ - spec/rails_app/tmp/cache/assets/CE0/ED0/sprockets%2Faffa2b71029862880913b9ec3673e1a5
180
+ - spec/rails_app/tmp/cache/assets/CC5/EB0/sprockets%2F940a62ef7993c65b7208eba436378d79
181
+ - spec/rails_app/tmp/cache/assets/DDC/400/sprockets%2Fcffd775d018f68ce5dba1ee0d951a994
182
+ - spec/rails_app/tmp/cache/assets/CB4/480/sprockets%2F98f3b0197247ae392ee2a0ed56181177
183
+ - spec/rails_app/tmp/cache/assets/DBF/B80/sprockets%2Fd2a79d7ae86da898bfe285ca39e9168f
184
+ - spec/rails_app/tmp/pids/server.pid
185
+ - spec/rails_app/script/rails
186
+ - spec/rails_app/config.ru
187
+ - README.md
188
+ - Rakefile
189
+ - Gemfile
190
+ homepage: http://github.com/FUT/iam
191
+ licenses:
192
+ - MIT
193
+ post_install_message:
194
+ rdoc_options: []
195
+ require_paths:
196
+ - lib
197
+ required_ruby_version: !ruby/object:Gem::Requirement
198
+ none: false
199
+ requirements:
200
+ - - ! '>='
201
+ - !ruby/object:Gem::Version
202
+ version: '0'
203
+ required_rubygems_version: !ruby/object:Gem::Requirement
204
+ none: false
205
+ requirements:
206
+ - - ! '>='
207
+ - !ruby/object:Gem::Version
208
+ version: '0'
209
+ requirements: []
210
+ rubyforge_project: iam
211
+ rubygems_version: 1.8.24
212
+ signing_key:
213
+ specification_version: 3
214
+ summary: Simple account switcher for Rails.
215
+ test_files: []