SYNR-537 and SYNR-539

More fixes to caching logic.  The client works without these, but some extraneous downloads might happen.
SYNR-541 + unit tests

Fixed up more caching bugs and a minor login issue.
Code review changes:
- Reverted spelling (-ple -> -pal)
- Changed getting submission files to use another variable in the download function
Merge pull request #79 from kaysoky/fileCachingFixesContinued

SYNR-537, SYNR-539, and SYNR-541