mirror of
https://github.com/neocities/neocities.git
synced 2025-08-03 00:02:00 +02:00
fix when unicode is used for filename and dir
This commit is contained in:
parent
e9afe63695
commit
b54b2a4818
4 changed files with 18 additions and 1 deletions
|
@ -423,6 +423,14 @@ describe 'api' do
|
|||
_(site_file_exists?('test.jpg')).must_equal true
|
||||
end
|
||||
|
||||
it 'works with unicode chars on filename and dir' do
|
||||
create_site
|
||||
basic_authorize @user, @pass
|
||||
post '/api/upload', '詩經/詩經.jpg' => Rack::Test::UploadedFile.new('./tests/files/詩經.jpg', 'image/jpeg')
|
||||
_(res[:result]).must_equal 'success'
|
||||
_(site_file_exists?('詩經/詩經.jpg')).must_equal true
|
||||
end
|
||||
|
||||
it 'succeeds with two files' do
|
||||
create_site
|
||||
basic_authorize @user, @pass
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue