Separate code for testing if a file is Python into a new function

Also added a new unit test for the new function.
Merge pull request #30 from nicholasbishop/bishop_is_python_file

Separate code for testing if a file is Python into a new function