GPII-941: Added several tests, cleaned up and added text files for the configs, minor fixes in various places in the code