Skip to content

Commit

Permalink
email is working again
Browse files Browse the repository at this point in the history
  • Loading branch information
roca committed Dec 23, 2011
1 parent e0bb1d2 commit 9414883
Show file tree
Hide file tree
Showing 6 changed files with 1,846 additions and 3 deletions.
9 changes: 9 additions & 0 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,13 @@

# Expands the lines which load the assets
config.assets.debug = true
config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
:address => "smtp.gmail.com",
:port => 587,
:user_name => '[email protected]',
:password => 'jGQx8TG2XCWrN',
:authentication => 'plain',
:enable_starttls_auto => true }

end
13 changes: 13 additions & 0 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,17 @@

# Send deprecation notices to registered listeners
config.active_support.deprecation = :notify
config.assets.debug = true



config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
:address => "smtp.gmail.com",
:port => 587,
:user_name => '[email protected]',
:password => 'jGQx8TG2XCWrN',
:authentication => 'plain',
:enable_starttls_auto => true }

end
1 change: 1 addition & 0 deletions spec/controllers/sessions_controller_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@

end


describe "with valid email and password" do

before(:each) do
Expand Down
4 changes: 2 additions & 2 deletions spec/models/micropost_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@

before(:each) do
@another_user = Factory(:user, :username => Factory.next(:username), :email => Factory.next(:email))
@attr2 = { :content => "@#{@user.username} micropost directed at #{@user.name}" ,:in_reply_to => @user}
@attr2 = { :content => "@#{@user.username} micropost directed at #{@user.name}" ,:in_reply_to => @user.id}
@microposts = @another_user.microposts.create(@attr2)
end

Expand Down Expand Up @@ -71,7 +71,7 @@

@user_post = @user.microposts.create!(:content => "foo")
@other_post = @other_user.microposts.create!(:content => "bar")
@third_post = @third_user.microposts.create!(:content => "baz", :in_reply_to => @user)
@third_post = @third_user.microposts.create!(:content => "baz", :in_reply_to => @user.id)

@user.follow!(@other_user)
end
Expand Down
2 changes: 1 addition & 1 deletion spec/models/user_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@
@another_user = Factory(:user,:username => Factory.next(:username),:email => Factory.next(:email))
@mp1 = Factory(:micropost, :user => @user, :created_at => 1.day.ago)
@mp2 = Factory(:micropost, :user => @user, :created_at => 1.hour.ago)
@mp3 = Factory(:micropost, :user => @another_user, :created_at => 1.hour.ago, :in_reply_to => @user)
@mp3 = Factory(:micropost, :user => @another_user, :created_at => 1.hour.ago, :in_reply_to => @user.id)
end

it "should have a microposts attribute" do
Expand Down
Loading

0 comments on commit 9414883

Please sign in to comment.