-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Rails 3.2.1 does not start with rspec-rails 3.2.2 #1386
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I'm looking into this now. |
Thanks for hopping on it so quickly, @cupakromer. I'll hold off on the 3.3 release until this is done (I think everything else on our 3.3 list already got done). We should probably backport the fix to 3.2.3 as well, and I'll be happy to release that, too. |
I think I see the issue but I've been unable to reproduce the error. I'll need to be able to reproduce before I can ensure I've fixed the issue. @tagliala if you could please update this issue with the following I'd really appreciate it:
|
also, @olance if you could provide additional details I would appreciate it |
Sure! There you go:
|
From my debug session, I have found that around line 34 in I searched for |
What's in |
Ok, I've got it reproduced locally. The config is happy to take the option. The error only occurs once |
/config/environment.rb # Load the rails application
require File.expand_path('../application', __FILE__)
# Initialize the rails application
Project::Application.initialize! /script/rails #!/usr/bin/env ruby
# This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
APP_PATH = File.expand_path('../../config/application', __FILE__)
require File.expand_path('../../config/boot', __FILE__)
require 'rails/commands' |
No worries! Thanks for fixing it so quickly! |
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
@cupakromer thank you! no problem here 👍 |
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
This forces `ActionMailer::Base` to load, which then attempts to set the configuration, exposing the regression issue in #1386. Why the mailer generator and specs did not expose this problem is currently a mystery. I will dig further.
This fixes the spec suite to expose issues with `ActionMailer` being configured incorrectly when previews are not available. This addresses several issues: - The incorrect configuration options are only exposed once `ActionMailer::Base` is loaded; this forces the class to load in the mailer initializer and at the end of our script - This adds specs specifically for the "development" environment which were missing before; it appeared that by not setting the environment it would default to "development" per the script, however, when the command shells out the `RAILS_ENV` is already set to "test" from rspec running. To be certain we cover the other possible edge cases we specifically add more tests for `ActionMailer` not being available, and for a custom configuration being set after `rspec-rails` is loaded. - Despite us asking Rails to turn off eager loading in our custom script, several files were still getting eager loaded; this explicitly clears the eager load paths to stop this - This fixes how the mailer script is shelled out in Ruby 1.8.7; now the environment variables are properly formatted and standard error is piped to standard out Exposes the regression issue in #1386
This fixes the spec suite to expose issues with `ActionMailer` being configured incorrectly when previews are not available. This addresses several issues: - The incorrect configuration options are only exposed once `ActionMailer::Base` is loaded; this forces the class to load in the mailer initializer and at the end of our script - This adds specs specifically for the "development" environment which were missing before; it appeared that by not setting the environment it would default to "development" per the script, however, when the command shells out the `RAILS_ENV` is already set to "test" from rspec running. To be certain we cover the other possible edge cases we specifically add more tests for `ActionMailer` not being available, and for a custom configuration being set after `rspec-rails` is loaded. - Despite us asking Rails to turn off eager loading in our custom script, several files were still getting eager loaded; this explicitly clears the eager load paths to stop this - This fixes how the mailer script is shelled out in Ruby 1.8.7; now the environment variables are properly formatted and standard error is piped to standard out Exposes the regression issue in #1386
I just released 3.2.3 with @cupakromer's fix. |
thanks! |
It should be a consequence of #1327, as per #1327 (comment)
The text was updated successfully, but these errors were encountered: