Kill trailing whitespace in ruby files

This commit is contained in:
小太
2013-03-19 23:10:10 +11:00
parent c107f96cec
commit cba839ba76
319 changed files with 2710 additions and 2710 deletions

View File

@@ -7,23 +7,23 @@ class UploadsControllerTest < ActionController::TestCase
CurrentUser.user = @user
CurrentUser.ip_addr = "127.0.0.1"
end
teardown do
CurrentUser.user = nil
CurrentUser.ip_addr = nil
end
context "new action" do
should "render" do
get :new, {}, {:user_id => @user.id}
assert_response :success
end
context "for a post that has already been uploaded" do
setup do
@post = FactoryGirl.create(:post, :source => "aaa")
end
should "initialize the post" do
get :new, {:url => "aaa"}, {:user_id => @user.id}
assert_response :success
@@ -31,17 +31,17 @@ class UploadsControllerTest < ActionController::TestCase
end
end
end
context "index action" do
setup do
@upload = FactoryGirl.create(:source_upload)
end
should "render" do
get :index, {}, {:user_id => @user.id}
assert_response :success
end
context "with search parameters" do
should "render" do
get :index, {:search => {:source => @upload.source}}, {:user_id => @user.id}
@@ -49,18 +49,18 @@ class UploadsControllerTest < ActionController::TestCase
end
end
end
context "show action" do
setup do
@upload = FactoryGirl.create(:jpg_upload)
end
should "render" do
get :show, {:id => @upload.id}, {:user_id => @user.id}
assert_response :success
end
end
context "create action" do
should "create a new upload" do
assert_difference("Upload.count", 1) do
@@ -70,12 +70,12 @@ class UploadsControllerTest < ActionController::TestCase
end
end
end
context "update action" do
setup do
@upload = FactoryGirl.create(:jpg_upload)
end
should "process an unapproval" do
post :update, {:id => @upload.id}, {:user_id => @user.id}
@upload.reload