Fix the filename typo detection edge cases. Closes #1532 and some other bugs (#1539)

* Add a test for checking the filename of an empty file

To test #1532

* Test an irregular file with a typo

* Fix the filename typo detection edge cases

* Split the irregular file test into a seperate test

Probably easier to skip and certainly makes the maths easier

* Skip the test if mkfifo is missing

* Add the missing import

* Fix the test skip logic

* Write in the right language!

* Test filename checking on a binary file
2 files changed