summaryrefslogtreecommitdiffstats
path: root/test/functional/files_controller_test.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2014-11-20 19:57:06 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2014-11-20 19:57:06 +0000
commit36d487fe505fbad9b0bc18a4d8f7b435a211be4a (patch)
tree7bf75212c0d2a0ea45db6ea1ebc7fa8460a34648 /test/functional/files_controller_test.rb
parent2a43f1adbcbe155eb7c3c4a60c5c0c289dec2a0f (diff)
downloadredmine-36d487fe505fbad9b0bc18a4d8f7b435a211be4a.tar.gz
redmine-36d487fe505fbad9b0bc18a4d8f7b435a211be4a.zip
Replaced some #assert_tag with #assert_select.
git-svn-id: http://svn.redmine.org/redmine/trunk@13620 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/files_controller_test.rb')
-rw-r--r--test/functional/files_controller_test.rb10
1 files changed, 4 insertions, 6 deletions
diff --git a/test/functional/files_controller_test.rb b/test/functional/files_controller_test.rb
index 577a05f44..0c3043bf5 100644
--- a/test/functional/files_controller_test.rb
+++ b/test/functional/files_controller_test.rb
@@ -41,12 +41,10 @@ class FilesControllerTest < ActionController::TestCase
assert_not_nil assigns(:containers)
# file attached to the project
- assert_tag :a, :content => 'project_file.zip',
- :attributes => { :href => '/attachments/download/8/project_file.zip' }
+ assert_select 'a[href=?]', '/attachments/download/8/project_file.zip', :text => 'project_file.zip'
# file attached to a project's version
- assert_tag :a, :content => 'version_file.zip',
- :attributes => { :href => '/attachments/download/9/version_file.zip' }
+ assert_select 'a[href=?]', '/attachments/download/9/version_file.zip', :text => 'version_file.zip'
end
def test_new
@@ -55,7 +53,7 @@ class FilesControllerTest < ActionController::TestCase
assert_response :success
assert_template 'new'
- assert_tag 'select', :attributes => {:name => 'version_id'}
+ assert_select 'select[name=?]', 'version_id'
end
def test_new_without_versions
@@ -65,7 +63,7 @@ class FilesControllerTest < ActionController::TestCase
assert_response :success
assert_template 'new'
- assert_no_tag 'select', :attributes => {:name => 'version_id'}
+ assert_select 'select[name=?]', 'version_id', 0
end
def test_create_file