Extract file reading out of config

Should make it easier to start retro-fitting tests