[FIX] Added missing assignment in QueryContext#cast(Object,String).
[FIX] External variables with non-empty URI have to be declared.
Merge pull request #673 from LeoWoerteler/test-suite-fixes

Test Suite Fixes, merged by me because Christian is on vacation.
[FIX] Use canonical path for `File#exists()`

JUnit test `FNFileTest#move()` failed on OS X because OS X cannot resolve paths
like `./directory/file.txt/../file.txt`. `File#getCanonicalFile()` does, so
resolving using that function fixes the problem.
[ADD] XML Parsing: preserve spaces for xml:space='preserve'
Merge branch 'master' of github.com:BaseXdb/basex
Merge pull request #674 from JensErat/filetest-fix

Fix FNFileTest-JUnit test on OS X
[MIN] XQuery, file:copy(): use canonical path for all tests
[FIX] XQuery, File Module, path encodings: only decode file:/// URLs
[FIX] XQuery, random:integer(): return 0 for invalid values. Closes #671
[FIX] XQuery, resolve-uri(): reduce check to single slash
[FIX] XQuery, resolve-uri(): reduce check to single slash. Closes #670
Merge branch 'master' of github.com:BaseXdb/basex
[FIX] Commands, CHECK: rebuild db if input document has been changed
[FIX] Commands, CHECK: rebuild db if input document has been changed
[FIX] XQuery, typeswitch: handle identical branches. Closes #661.
[FIX] XQuery, typeswitch: handle identical branches.
[MIN] comments
[FIX] XQuery, formatting dates: timezone output. Closes #677
[FIX] XQuery, function compilation: reset context value