From: Toshi MARUYAMA Date: Tue, 22 Mar 2011 10:45:39 +0000 (+0000) Subject: scm: filesystem: add test of no extension file whose content is only ASCII can be... X-Git-Tag: 1.2.0~646 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=ec2fd81f7bfbf937046dd9741dce21bac126e044;p=redmine.git scm: filesystem: add test of no extension file whose content is only ASCII can be showing (#6256). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5198 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/test/functional/repositories_filesystem_controller_test.rb b/test/functional/repositories_filesystem_controller_test.rb index 4cd8f1bb0..7f569b611 100644 --- a/test/functional/repositories_filesystem_controller_test.rb +++ b/test/functional/repositories_filesystem_controller_test.rb @@ -46,7 +46,7 @@ class RepositoriesFilesystemControllerTest < ActionController::TestCase def test_browse_root @repository.fetch_changesets @repository.reload - get :show, :id => 3 + get :show, :id => PRJ_ID assert_response :success assert_template 'show' assert_not_nil assigns(:entries) @@ -54,6 +54,16 @@ class RepositoriesFilesystemControllerTest < ActionController::TestCase assert_not_nil assigns(:changesets) assert assigns(:changesets).size == 0 end + + def test_show_no_extension + get :entry, :id => PRJ_ID, :path => ['test'] + assert_response :success + assert_template 'entry' + assert_tag :tag => 'th', + :content => '1', + :attributes => { :class => 'line-num' }, + :sibling => { :tag => 'td', :content => /TEST CAT/ } + end else puts "Filesystem test repository NOT FOUND. Skipping functional tests !!!" def test_fake; assert true end