Matthias Günther

Results 122 issues of Matthias Günther

https://github.com/tyabe/padrino-decorator looks okay, maybe better then app/helpers.

feature

Better: ```ruby expect(User).to receive(:find_by_password_reset_token) .with('1') .and_return(user) ``` instead of `expect(User).to receive(:find_by_password_reset_token).with('1').and_return(user)`

feature

Instead of `expect(last_response).to be_redirect` better do `expect(last_response.location).to include('password_forget')`. The best solution would be to create the routes dynamic (e.g. ` expect(last_response.url).to be_equal(url(:password_forget, :new))`.

feature

We delegate the responsibility for sending the password reset mail into `UserPasswordResetMail` class. Here are the tests for the class: ```ruby # spec/lib/user_password_reset_mail_spec.rb require 'spec_helper' RSpec.describe UserPasswordResetMail do let(:user) {...

chapter

- **https://www.fabricationgem.org/** - create a branch where uses can compare the runtime - seems to hit less the database: https://stackoverflow.com/questions/12179107/comparing-factory-girl-with-fabrication - good post by steve klabnik: http://blog.steveklabnik.com/posts/2012-07-14-why-i-don-t-like-factory_girl

feature
chapter

Need to update them `DEPRECATION WARNING: Directly inheriting from ActiveRecord::Migration is deprecated. Please specify the Rails release the migration was written for: class AddRegistrationFieldsToUsers < ActiveRecord::Migration[4.2] (called from block in...

Is doing to many things ... sending mails and `encrypt_confirmation_code` => this should be another service.

Provide a simple downloadable script to install ruby with rbenv!

chapter