Bug 893276: Only write simple-storage to disk after it has been changed.
Merge with master
Switch to using fs APIs for file reading and writing.
Address review comments by logging errors and catching them in tests and updating the hash at the end of successful writes only.
Merge pull request #1134 from Mossop/bug893276_2

Bug 893276: Only write simple-storage to disk after it has been changed. r=@gozala