mongo_session_store 3.1.0 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (85) hide show
  1. checksums.yaml +5 -5
  2. data/.travis.yml +56 -14
  3. data/CHANGELOG.md +12 -2
  4. data/README.md +7 -1
  5. data/gemfiles/rails-4.0-mongo.gemfile +1 -1
  6. data/gemfiles/rails-4.0-mongoid.gemfile +1 -1
  7. data/gemfiles/rails-4.1-mongo.gemfile +1 -1
  8. data/gemfiles/rails-4.1-mongoid.gemfile +1 -1
  9. data/gemfiles/rails-4.2-mongo.gemfile +1 -1
  10. data/gemfiles/rails-4.2-mongoid.gemfile +1 -1
  11. data/gemfiles/rails-5.0-mongo.gemfile +1 -1
  12. data/gemfiles/rails-5.0-mongoid.gemfile +1 -1
  13. data/gemfiles/rails-5.1-mongo.gemfile +9 -0
  14. data/gemfiles/rails-5.1-mongoid.gemfile +9 -0
  15. data/gemfiles/rails-5.2-mongo.gemfile +9 -0
  16. data/gemfiles/rails-5.2-mongoid.gemfile +9 -0
  17. data/lib/mongo_session_store.rb +2 -0
  18. data/lib/mongo_session_store/mongo_store.rb +1 -1
  19. data/lib/mongo_session_store/version.rb +1 -1
  20. data/mongo_session_store.gemspec +2 -1
  21. data/spec/integrations/devise_spec.rb +17 -2
  22. data/spec/rails_helper.rb +4 -1
  23. data/spec/support/apps/rails_4.0_app/app/views/home/index.html.erb +5 -6
  24. data/spec/support/apps/rails_4.1_app/app/views/home/index.html.erb +5 -6
  25. data/spec/support/apps/rails_4.2_app/app/views/home/index.html.erb +3 -4
  26. data/spec/support/apps/rails_5.0_app/app/views/home/index.html.erb +3 -4
  27. data/spec/support/apps/rails_5.1_app/Rakefile +6 -0
  28. data/spec/support/apps/rails_5.1_app/app/controllers/application_controller.rb +3 -0
  29. data/spec/support/apps/rails_5.1_app/app/controllers/home_controller.rb +2 -0
  30. data/spec/support/apps/rails_5.1_app/app/models/application_record.rb +3 -0
  31. data/spec/support/apps/rails_5.1_app/app/models/user.rb +5 -0
  32. data/spec/support/apps/rails_5.1_app/app/views/home/index.html.erb +9 -0
  33. data/spec/support/apps/rails_5.1_app/app/views/layouts/application.html.erb +15 -0
  34. data/spec/support/apps/rails_5.1_app/bin/bundle +3 -0
  35. data/spec/support/apps/rails_5.1_app/bin/rails +4 -0
  36. data/spec/support/apps/rails_5.1_app/bin/rake +4 -0
  37. data/spec/support/apps/rails_5.1_app/bin/setup +34 -0
  38. data/spec/support/apps/rails_5.1_app/bin/update +29 -0
  39. data/spec/support/apps/rails_5.1_app/config.ru +5 -0
  40. data/spec/support/apps/rails_5.1_app/config/application.rb +12 -0
  41. data/spec/support/apps/rails_5.1_app/config/boot.rb +5 -0
  42. data/spec/support/apps/rails_5.1_app/config/database.yml +11 -0
  43. data/spec/support/apps/rails_5.1_app/config/environment.rb +5 -0
  44. data/spec/support/apps/rails_5.1_app/config/environments/development.rb +12 -0
  45. data/spec/support/apps/rails_5.1_app/config/environments/test.rb +19 -0
  46. data/spec/support/apps/rails_5.1_app/config/initializers/devise.rb +254 -0
  47. data/spec/support/apps/rails_5.1_app/config/initializers/session_store.rb +1 -0
  48. data/spec/support/apps/rails_5.1_app/config/locales/en.yml +23 -0
  49. data/spec/support/apps/rails_5.1_app/config/mongo.yml +11 -0
  50. data/spec/support/apps/rails_5.1_app/config/mongoid.yml +13 -0
  51. data/spec/support/apps/rails_5.1_app/config/routes.rb +4 -0
  52. data/spec/support/apps/rails_5.1_app/config/secrets.yml +22 -0
  53. data/spec/support/apps/rails_5.1_app/db/migrate/20140301171212_add_devise_users.rb +11 -0
  54. data/spec/support/apps/rails_5.1_app/db/schema.rb +23 -0
  55. data/spec/support/apps/rails_5.1_app/log/.keep +0 -0
  56. data/spec/support/apps/rails_5.2_app/Rakefile +6 -0
  57. data/spec/support/apps/rails_5.2_app/app/controllers/application_controller.rb +3 -0
  58. data/spec/support/apps/rails_5.2_app/app/controllers/home_controller.rb +2 -0
  59. data/spec/support/apps/rails_5.2_app/app/models/application_record.rb +3 -0
  60. data/spec/support/apps/rails_5.2_app/app/models/user.rb +5 -0
  61. data/spec/support/apps/rails_5.2_app/app/views/home/index.html.erb +9 -0
  62. data/spec/support/apps/rails_5.2_app/app/views/layouts/application.html.erb +15 -0
  63. data/spec/support/apps/rails_5.2_app/bin/bundle +3 -0
  64. data/spec/support/apps/rails_5.2_app/bin/rails +4 -0
  65. data/spec/support/apps/rails_5.2_app/bin/rake +4 -0
  66. data/spec/support/apps/rails_5.2_app/bin/setup +34 -0
  67. data/spec/support/apps/rails_5.2_app/bin/update +29 -0
  68. data/spec/support/apps/rails_5.2_app/config.ru +5 -0
  69. data/spec/support/apps/rails_5.2_app/config/application.rb +12 -0
  70. data/spec/support/apps/rails_5.2_app/config/boot.rb +5 -0
  71. data/spec/support/apps/rails_5.2_app/config/database.yml +11 -0
  72. data/spec/support/apps/rails_5.2_app/config/environment.rb +5 -0
  73. data/spec/support/apps/rails_5.2_app/config/environments/development.rb +12 -0
  74. data/spec/support/apps/rails_5.2_app/config/environments/test.rb +19 -0
  75. data/spec/support/apps/rails_5.2_app/config/initializers/devise.rb +254 -0
  76. data/spec/support/apps/rails_5.2_app/config/initializers/session_store.rb +1 -0
  77. data/spec/support/apps/rails_5.2_app/config/locales/en.yml +23 -0
  78. data/spec/support/apps/rails_5.2_app/config/mongo.yml +11 -0
  79. data/spec/support/apps/rails_5.2_app/config/mongoid.yml +13 -0
  80. data/spec/support/apps/rails_5.2_app/config/routes.rb +4 -0
  81. data/spec/support/apps/rails_5.2_app/config/secrets.yml +22 -0
  82. data/spec/support/apps/rails_5.2_app/db/migrate/20140301171212_add_devise_users.rb +11 -0
  83. data/spec/support/apps/rails_5.2_app/db/schema.rb +23 -0
  84. data/spec/support/apps/rails_5.2_app/log/.keep +0 -0
  85. metadata +139 -6
@@ -0,0 +1 @@
1
+ Rails.application.config.session_store :"#{mongo_orm}_store"
@@ -0,0 +1,23 @@
1
+ # Files in the config/locales directory are used for internationalization
2
+ # and are automatically loaded by Rails. If you want to use locales other
3
+ # than English, add the necessary files in this directory.
4
+ #
5
+ # To use the locales, use `I18n.t`:
6
+ #
7
+ # I18n.t 'hello'
8
+ #
9
+ # In views, this is aliased to just `t`:
10
+ #
11
+ # <%= t('hello') %>
12
+ #
13
+ # To use a different locale, set it with `I18n.locale`:
14
+ #
15
+ # I18n.locale = :es
16
+ #
17
+ # This would use the information in config/locales/es.yml.
18
+ #
19
+ # To learn more, please read the Rails Internationalization guide
20
+ # available at http://guides.rubyonrails.org/i18n.html.
21
+
22
+ en:
23
+ hello: "Hello world"
@@ -0,0 +1,11 @@
1
+ defaults: &defaults
2
+ host: 127.0.0.1
3
+ port: 27017
4
+
5
+ development:
6
+ <<: *defaults
7
+ database: test_database
8
+
9
+ test:
10
+ <<: *defaults
11
+ database: test_database
@@ -0,0 +1,13 @@
1
+ development:
2
+ clients:
3
+ default:
4
+ database: test_database
5
+ hosts:
6
+ - 127.0.0.1:27017
7
+
8
+ test:
9
+ clients:
10
+ default:
11
+ database: test_database
12
+ hosts:
13
+ - 127.0.0.1:27017
@@ -0,0 +1,4 @@
1
+ Rails.application.routes.draw do
2
+ devise_for :users
3
+ root :to => "home#index"
4
+ end
@@ -0,0 +1,22 @@
1
+ # Be sure to restart your server when you modify this file.
2
+
3
+ # Your secret key is used for verifying the integrity of signed cookies.
4
+ # If you change this key, all old signed cookies will become invalid!
5
+
6
+ # Make sure the secret is at least 30 characters and all random,
7
+ # no regular words or you'll be exposed to dictionary attacks.
8
+ # You can use `rails secret` to generate a secure secret key.
9
+
10
+ # Make sure the secrets in this file are kept private
11
+ # if you're sharing your code publicly.
12
+
13
+ development:
14
+ secret_key_base: cef010831c3c4a0f52653b0a5664ceb8091b9dcfb5feabe3ffcc0e08c006d70414dfb3cd1ba9d1273fe2f49f6b9938a7c22605647e783ce04f08415acc07d887
15
+
16
+ test:
17
+ secret_key_base: a7f1932ee2f6b72991e40ff14bf4ee16030a9f00fe2294054d39a186be297424a69034528966a2ee61ab959131137bcd7f6ba80491684da11a17c8f7af661abb
18
+
19
+ # Do not keep production secrets in the repository,
20
+ # instead read values from the environment.
21
+ production:
22
+ secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
@@ -0,0 +1,11 @@
1
+ class AddDeviseUsers < ActiveRecord::Migration[5.2]
2
+ def change
3
+ create_table(:users) do |t|
4
+ t.string :email, :null => false, :default => ""
5
+ t.string :encrypted_password, :null => false, :default => ""
6
+ t.timestamps
7
+ end
8
+
9
+ add_index :users, :email, :unique => true
10
+ end
11
+ end
@@ -0,0 +1,23 @@
1
+ # This file is auto-generated from the current state of the database. Instead
2
+ # of editing this file, please use the migrations feature of Active Record to
3
+ # incrementally modify your database, and then regenerate this schema definition.
4
+ #
5
+ # Note that this schema.rb definition is the authoritative source for your
6
+ # database schema. If you need to create the application database on another
7
+ # system, you should be using db:schema:load, not running all the migrations
8
+ # from scratch. The latter is a flawed and unsustainable approach (the more migrations
9
+ # you'll amass, the slower it'll run and the greater likelihood for issues).
10
+ #
11
+ # It's strongly recommended that you check this file into your version control system.
12
+
13
+ ActiveRecord::Schema.define(version: 2014_03_01_171212) do
14
+
15
+ create_table "users", force: :cascade do |t|
16
+ t.string "email", default: "", null: false
17
+ t.string "encrypted_password", default: "", null: false
18
+ t.datetime "created_at", null: false
19
+ t.datetime "updated_at", null: false
20
+ t.index ["email"], name: "index_users_on_email", unique: true
21
+ end
22
+
23
+ end
File without changes
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongo_session_store
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tom de Bruijn
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2017-05-02 00:00:00.000000000 Z
15
+ date: 2019-04-26 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: actionpack
@@ -48,14 +48,28 @@ dependencies:
48
48
  requirements:
49
49
  - - "~>"
50
50
  - !ruby/object:Gem::Version
51
- version: '3'
51
+ version: '3.6'
52
52
  type: :development
53
53
  prerelease: false
54
54
  version_requirements: !ruby/object:Gem::Requirement
55
55
  requirements:
56
56
  - - "~>"
57
57
  - !ruby/object:Gem::Version
58
- version: '3'
58
+ version: '3.6'
59
+ - !ruby/object:Gem::Dependency
60
+ name: capybara
61
+ requirement: !ruby/object:Gem::Requirement
62
+ requirements:
63
+ - - "~>"
64
+ - !ruby/object:Gem::Version
65
+ version: 2.15.0
66
+ type: :development
67
+ prerelease: false
68
+ version_requirements: !ruby/object:Gem::Requirement
69
+ requirements:
70
+ - - "~>"
71
+ - !ruby/object:Gem::Version
72
+ version: 2.15.0
59
73
  - !ruby/object:Gem::Dependency
60
74
  name: pry
61
75
  requirement: !ruby/object:Gem::Requirement
@@ -137,6 +151,10 @@ files:
137
151
  - gemfiles/rails-4.2-mongoid.gemfile
138
152
  - gemfiles/rails-5.0-mongo.gemfile
139
153
  - gemfiles/rails-5.0-mongoid.gemfile
154
+ - gemfiles/rails-5.1-mongo.gemfile
155
+ - gemfiles/rails-5.1-mongoid.gemfile
156
+ - gemfiles/rails-5.2-mongo.gemfile
157
+ - gemfiles/rails-5.2-mongoid.gemfile
140
158
  - lib/mongo_session_store.rb
141
159
  - lib/mongo_session_store/mongo_store.rb
142
160
  - lib/mongo_session_store/mongo_store_base.rb
@@ -266,6 +284,64 @@ files:
266
284
  - spec/support/apps/rails_5.0_app/db/migrate/20140301171212_add_devise_users.rb
267
285
  - spec/support/apps/rails_5.0_app/db/schema.rb
268
286
  - spec/support/apps/rails_5.0_app/log/.keep
287
+ - spec/support/apps/rails_5.1_app/Rakefile
288
+ - spec/support/apps/rails_5.1_app/app/controllers/application_controller.rb
289
+ - spec/support/apps/rails_5.1_app/app/controllers/home_controller.rb
290
+ - spec/support/apps/rails_5.1_app/app/models/application_record.rb
291
+ - spec/support/apps/rails_5.1_app/app/models/user.rb
292
+ - spec/support/apps/rails_5.1_app/app/views/home/index.html.erb
293
+ - spec/support/apps/rails_5.1_app/app/views/layouts/application.html.erb
294
+ - spec/support/apps/rails_5.1_app/bin/bundle
295
+ - spec/support/apps/rails_5.1_app/bin/rails
296
+ - spec/support/apps/rails_5.1_app/bin/rake
297
+ - spec/support/apps/rails_5.1_app/bin/setup
298
+ - spec/support/apps/rails_5.1_app/bin/update
299
+ - spec/support/apps/rails_5.1_app/config.ru
300
+ - spec/support/apps/rails_5.1_app/config/application.rb
301
+ - spec/support/apps/rails_5.1_app/config/boot.rb
302
+ - spec/support/apps/rails_5.1_app/config/database.yml
303
+ - spec/support/apps/rails_5.1_app/config/environment.rb
304
+ - spec/support/apps/rails_5.1_app/config/environments/development.rb
305
+ - spec/support/apps/rails_5.1_app/config/environments/test.rb
306
+ - spec/support/apps/rails_5.1_app/config/initializers/devise.rb
307
+ - spec/support/apps/rails_5.1_app/config/initializers/session_store.rb
308
+ - spec/support/apps/rails_5.1_app/config/locales/en.yml
309
+ - spec/support/apps/rails_5.1_app/config/mongo.yml
310
+ - spec/support/apps/rails_5.1_app/config/mongoid.yml
311
+ - spec/support/apps/rails_5.1_app/config/routes.rb
312
+ - spec/support/apps/rails_5.1_app/config/secrets.yml
313
+ - spec/support/apps/rails_5.1_app/db/migrate/20140301171212_add_devise_users.rb
314
+ - spec/support/apps/rails_5.1_app/db/schema.rb
315
+ - spec/support/apps/rails_5.1_app/log/.keep
316
+ - spec/support/apps/rails_5.2_app/Rakefile
317
+ - spec/support/apps/rails_5.2_app/app/controllers/application_controller.rb
318
+ - spec/support/apps/rails_5.2_app/app/controllers/home_controller.rb
319
+ - spec/support/apps/rails_5.2_app/app/models/application_record.rb
320
+ - spec/support/apps/rails_5.2_app/app/models/user.rb
321
+ - spec/support/apps/rails_5.2_app/app/views/home/index.html.erb
322
+ - spec/support/apps/rails_5.2_app/app/views/layouts/application.html.erb
323
+ - spec/support/apps/rails_5.2_app/bin/bundle
324
+ - spec/support/apps/rails_5.2_app/bin/rails
325
+ - spec/support/apps/rails_5.2_app/bin/rake
326
+ - spec/support/apps/rails_5.2_app/bin/setup
327
+ - spec/support/apps/rails_5.2_app/bin/update
328
+ - spec/support/apps/rails_5.2_app/config.ru
329
+ - spec/support/apps/rails_5.2_app/config/application.rb
330
+ - spec/support/apps/rails_5.2_app/config/boot.rb
331
+ - spec/support/apps/rails_5.2_app/config/database.yml
332
+ - spec/support/apps/rails_5.2_app/config/environment.rb
333
+ - spec/support/apps/rails_5.2_app/config/environments/development.rb
334
+ - spec/support/apps/rails_5.2_app/config/environments/test.rb
335
+ - spec/support/apps/rails_5.2_app/config/initializers/devise.rb
336
+ - spec/support/apps/rails_5.2_app/config/initializers/session_store.rb
337
+ - spec/support/apps/rails_5.2_app/config/locales/en.yml
338
+ - spec/support/apps/rails_5.2_app/config/mongo.yml
339
+ - spec/support/apps/rails_5.2_app/config/mongoid.yml
340
+ - spec/support/apps/rails_5.2_app/config/routes.rb
341
+ - spec/support/apps/rails_5.2_app/config/secrets.yml
342
+ - spec/support/apps/rails_5.2_app/db/migrate/20140301171212_add_devise_users.rb
343
+ - spec/support/apps/rails_5.2_app/db/schema.rb
344
+ - spec/support/apps/rails_5.2_app/log/.keep
269
345
  - spec/support/helpers/session_id_helper.rb
270
346
  - spec/support/helpers/test_database_helper.rb
271
347
  homepage: http://github.com/mongoid/mongo_session_store
@@ -287,8 +363,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
287
363
  - !ruby/object:Gem::Version
288
364
  version: '0'
289
365
  requirements: []
290
- rubyforge_project:
291
- rubygems_version: 2.6.10
366
+ rubygems_version: 3.0.2
292
367
  signing_key:
293
368
  specification_version: 4
294
369
  summary: Rails session stores for Mongoid, or any other ODM. Rails 4 compatible.
@@ -415,5 +490,63 @@ test_files:
415
490
  - spec/support/apps/rails_5.0_app/db/migrate/20140301171212_add_devise_users.rb
416
491
  - spec/support/apps/rails_5.0_app/db/schema.rb
417
492
  - spec/support/apps/rails_5.0_app/log/.keep
493
+ - spec/support/apps/rails_5.1_app/Rakefile
494
+ - spec/support/apps/rails_5.1_app/app/controllers/application_controller.rb
495
+ - spec/support/apps/rails_5.1_app/app/controllers/home_controller.rb
496
+ - spec/support/apps/rails_5.1_app/app/models/application_record.rb
497
+ - spec/support/apps/rails_5.1_app/app/models/user.rb
498
+ - spec/support/apps/rails_5.1_app/app/views/home/index.html.erb
499
+ - spec/support/apps/rails_5.1_app/app/views/layouts/application.html.erb
500
+ - spec/support/apps/rails_5.1_app/bin/bundle
501
+ - spec/support/apps/rails_5.1_app/bin/rails
502
+ - spec/support/apps/rails_5.1_app/bin/rake
503
+ - spec/support/apps/rails_5.1_app/bin/setup
504
+ - spec/support/apps/rails_5.1_app/bin/update
505
+ - spec/support/apps/rails_5.1_app/config.ru
506
+ - spec/support/apps/rails_5.1_app/config/application.rb
507
+ - spec/support/apps/rails_5.1_app/config/boot.rb
508
+ - spec/support/apps/rails_5.1_app/config/database.yml
509
+ - spec/support/apps/rails_5.1_app/config/environment.rb
510
+ - spec/support/apps/rails_5.1_app/config/environments/development.rb
511
+ - spec/support/apps/rails_5.1_app/config/environments/test.rb
512
+ - spec/support/apps/rails_5.1_app/config/initializers/devise.rb
513
+ - spec/support/apps/rails_5.1_app/config/initializers/session_store.rb
514
+ - spec/support/apps/rails_5.1_app/config/locales/en.yml
515
+ - spec/support/apps/rails_5.1_app/config/mongo.yml
516
+ - spec/support/apps/rails_5.1_app/config/mongoid.yml
517
+ - spec/support/apps/rails_5.1_app/config/routes.rb
518
+ - spec/support/apps/rails_5.1_app/config/secrets.yml
519
+ - spec/support/apps/rails_5.1_app/db/migrate/20140301171212_add_devise_users.rb
520
+ - spec/support/apps/rails_5.1_app/db/schema.rb
521
+ - spec/support/apps/rails_5.1_app/log/.keep
522
+ - spec/support/apps/rails_5.2_app/Rakefile
523
+ - spec/support/apps/rails_5.2_app/app/controllers/application_controller.rb
524
+ - spec/support/apps/rails_5.2_app/app/controllers/home_controller.rb
525
+ - spec/support/apps/rails_5.2_app/app/models/application_record.rb
526
+ - spec/support/apps/rails_5.2_app/app/models/user.rb
527
+ - spec/support/apps/rails_5.2_app/app/views/home/index.html.erb
528
+ - spec/support/apps/rails_5.2_app/app/views/layouts/application.html.erb
529
+ - spec/support/apps/rails_5.2_app/bin/bundle
530
+ - spec/support/apps/rails_5.2_app/bin/rails
531
+ - spec/support/apps/rails_5.2_app/bin/rake
532
+ - spec/support/apps/rails_5.2_app/bin/setup
533
+ - spec/support/apps/rails_5.2_app/bin/update
534
+ - spec/support/apps/rails_5.2_app/config.ru
535
+ - spec/support/apps/rails_5.2_app/config/application.rb
536
+ - spec/support/apps/rails_5.2_app/config/boot.rb
537
+ - spec/support/apps/rails_5.2_app/config/database.yml
538
+ - spec/support/apps/rails_5.2_app/config/environment.rb
539
+ - spec/support/apps/rails_5.2_app/config/environments/development.rb
540
+ - spec/support/apps/rails_5.2_app/config/environments/test.rb
541
+ - spec/support/apps/rails_5.2_app/config/initializers/devise.rb
542
+ - spec/support/apps/rails_5.2_app/config/initializers/session_store.rb
543
+ - spec/support/apps/rails_5.2_app/config/locales/en.yml
544
+ - spec/support/apps/rails_5.2_app/config/mongo.yml
545
+ - spec/support/apps/rails_5.2_app/config/mongoid.yml
546
+ - spec/support/apps/rails_5.2_app/config/routes.rb
547
+ - spec/support/apps/rails_5.2_app/config/secrets.yml
548
+ - spec/support/apps/rails_5.2_app/db/migrate/20140301171212_add_devise_users.rb
549
+ - spec/support/apps/rails_5.2_app/db/schema.rb
550
+ - spec/support/apps/rails_5.2_app/log/.keep
418
551
  - spec/support/helpers/session_id_helper.rb
419
552
  - spec/support/helpers/test_database_helper.rb