Added tests for writeToJsonFile config