Test cleanup.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8475 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2012-01-02 19:44:37 +00:00
parent bbba385198
commit 606ca39d10
11 changed files with 4 additions and 40 deletions

View File

@ -83,8 +83,4 @@ class ApiTest::AttachmentsTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -120,8 +120,4 @@ class ApiTest::IssueCategoriesTest < ActionController::IntegrationTest
assert_nil IssueCategory.find_by_id(1)
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -103,8 +103,4 @@ class ApiTest::IssueRelationsTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -576,8 +576,4 @@ class ApiTest::IssuesTest < ActionController::IntegrationTest
assert_nil Issue.find_by_id(6)
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -95,8 +95,4 @@ class ApiTest::NewsTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -290,8 +290,4 @@ class ApiTest::ProjectsTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -56,8 +56,4 @@ class ApiTest::QueriesTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -145,8 +145,4 @@ class ApiTest::TimeEntriesTest < ActionController::IntegrationTest
assert_nil TimeEntry.find_by_id(2)
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -312,8 +312,4 @@ class ApiTest::UsersTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -121,8 +121,4 @@ class ApiTest::VersionsTest < ActionController::IntegrationTest
end
end
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
end

View File

@ -62,6 +62,10 @@ class ActiveSupport::TestCase
ActiveSupport::TestCase.fixture_path + "/files/#{name}", mime, true)
end
def credentials(user, password=nil)
ActionController::HttpAuthentication::Basic.encode_credentials(user, password || user)
end
# Mock out a file
def self.mock_file
file = 'a_file.png'