1) filesize() is meh.  Let's use md5_file() instead.  These tests are all on local files anyway, no?
2) Rather than having one or the other, let's have both a text *and* a binary file, based on the assumption that if they could behave differently during tests, they could behave differently during production.  The cost to do this is low.