Perform user expansion when uploading files from the CLI.

Don't ignore missing files - allow an exception to be raised.
Add extra CLI file upload unit tests.

Fixes #59.