nyauth 0.0.1 → 0.0.2

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.
@@ -0,0 +1,15 @@
1
+ require "rails_helper"
2
+
3
+ RSpec.describe Nyauth::UserMailer do
4
+ describe '#request_confirmation' do
5
+ let(:user) { create(:user, :requested_confirmation) }
6
+ subject(:mail) { Nyauth::UserMailer.request_confirmation(user) }
7
+ it { expect(mail).to have_body_text 'Plese confirm your email' }
8
+ end
9
+
10
+ describe '#request_new_password' do
11
+ let(:user) { create(:user, :requested_new_password) }
12
+ subject(:mail) { Nyauth::UserMailer.request_new_password(user) }
13
+ it { expect(mail).to have_body_text 'Plese set your new password' }
14
+ end
15
+ end
data/spec/rails_helper.rb CHANGED
@@ -22,6 +22,8 @@ RSpec.configure do |config|
22
22
  config.include FactoryGirl::Syntax::Methods
23
23
  config.include ControllerMacros, type: :controller
24
24
  config.include FeatureMacros, type: :feature
25
+ config.include EmailSpec::Helpers, type: :mailer
26
+ config.include EmailSpec::Matchers, type: :mailer
25
27
 
26
28
  config.before(:suite) do
27
29
  DatabaseRewinder.clean
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nyauth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - ppworks
@@ -93,6 +93,7 @@ files:
93
93
  - app/assets/javascripts/nyauth/application.js
94
94
  - app/assets/stylesheets/nyauth/application.css
95
95
  - app/controllers/concerns/nyauth/session_concern.rb
96
+ - app/controllers/nyauth/base_controller.rb
96
97
  - app/controllers/nyauth/confirmation_requests_controller.rb
97
98
  - app/controllers/nyauth/confirmations_controller.rb
98
99
  - app/controllers/nyauth/new_password_requests_controller.rb
@@ -185,6 +186,7 @@ files:
185
186
  - spec/featrues/nyauth/passwords_spec.rb
186
187
  - spec/featrues/nyauth/registrations_spec.rb
187
188
  - spec/featrues/nyauth/sessions_spec.rb
189
+ - spec/mailers/nyauth/user_mailer_spec.rb
188
190
  - spec/models/user_spec.rb
189
191
  - spec/rails_helper.rb
190
192
  - spec/spec_helper.rb
@@ -268,6 +270,7 @@ test_files:
268
270
  - spec/featrues/nyauth/passwords_spec.rb
269
271
  - spec/featrues/nyauth/registrations_spec.rb
270
272
  - spec/featrues/nyauth/sessions_spec.rb
273
+ - spec/mailers/nyauth/user_mailer_spec.rb
271
274
  - spec/models/user_spec.rb
272
275
  - spec/rails_helper.rb
273
276
  - spec/spec_helper.rb