set -x

cd /tmp
svnadmin create repos
svn co file:///tmp/repos wc
cd wc
svn mkdir upstream
touch "upstream/first.txt"
svn ci -m "Initial"
svn copy upstream custom
svn ci -m "Customization"
touch "upstream/filename with spaces.txt"
svn add upstream/filename\ with\ spaces.txt
svn ci -m "Add spaced filename" upstream
cd custom
svn merge -r 2:3 file:///tmp/repos/upstream .
svn copy "../upstream/filename with spaces.txt" new.txt
grep copyfrom .svn/entries
svn ci -m "This trigger the error via http://, not via file://" .

