title: How do I unit-test saving file to the disk?
body: <p>I know that it's strongly recommended to run unit-tests <b>in separation from file system</b>, because if you do touch file system in your test, you also test file system itself. OK, that's reasonable.<br>
  My question is, if I want to test file saving to the disk, what do I do? As with database, I separate an interface that is responsible for database access, and then create another implementation of this for my tests? Or may be there's some other way?</p>