Bug 915156 - reimplement cacheFile using node fs.
Bug 915156 - fix the test runs