This commit is contained in:
Karel Pičman 2019-11-08 15:55:58 +01:00
parent dbb87fb684
commit d54526e1ff
3 changed files with 11 additions and 21 deletions

View File

@ -33,7 +33,7 @@ class DmsfWebdavCustomMiddlewareTest < RedmineDmsf::Test::IntegrationTest
def test_options_for_root_path
process :options, '/'
assert_response defined?(EasyExtensions) ? :method_not_allowed : :not_found
assert_response :success
end
def test_options_for_dmsf_root_path
@ -41,6 +41,16 @@ class DmsfWebdavCustomMiddlewareTest < RedmineDmsf::Test::IntegrationTest
assert_response :success
end
def test_propfind_for_root_path
process :propfind, '/'
assert_response :not_found
end
def test_propfind_for_dmsf_root_path
process :propfind, '/dmsf'
assert_response :not_found
end
def test_webdav_not_enabled
Setting.plugin_redmine_dmsf['dmsf_webdav'] = nil
process :options, '/dmsf/webdav'

View File

@ -176,14 +176,4 @@ class DmsfWebdavOptionsTest < RedmineDmsf::Test::IntegrationTest
assert_response :not_found
end
def test_ms_redirector_workaround_dmsf
process :options, '/dmsf', params: nil, headers: @jsmith
assert_response :success
end
def test_ms_redirector_workaround_root
process :options, '/', params: nil, headers: @jsmith
assert_response :success
end
end

View File

@ -177,14 +177,4 @@ class DmsfWebdavPropfindTest < RedmineDmsf::Test::IntegrationTest
assert response.body.include?("<d:displayname>#{project1_new_name}</d:displayname>")
end
def test_ms_redirector_workaround_dmsf
process :propfind, '/dmsf', params: nil, headers: @jsmith
assert_response :not_found
end
def test_ms_redirector_workaround_root
process :propfind, '/', params: nil, headers: @jsmith
assert_response :not_found
end
end